X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Fstream-ssl.c;h=51ce306353f0351fac5972b5bbb3ccfff7df2362;hb=f479c2f42b01cbb6fb0a60448f314021b1c3c9df;hp=6839341c1cf56161fedfb4923c35ce50ea38b2fa;hpb=2b494771fdaa05eeea2c9789b36e455e46468d41;p=openvswitch diff --git a/lib/stream-ssl.c b/lib/stream-ssl.c index 6839341c..51ce3063 100644 --- a/lib/stream-ssl.c +++ b/lib/stream-ssl.c @@ -155,7 +155,7 @@ static void ssl_close(struct stream *); static void ssl_clear_txbuf(struct ssl_stream *); static int interpret_ssl_error(const char *function, int ret, int error, int *want); -static DH *tmp_dh_callback(SSL *ssl, int is_export UNUSED, int keylength); +static DH *tmp_dh_callback(SSL *ssl, int is_export OVS_UNUSED, int keylength); static void log_ca_cert(const char *file_name, X509 *cert); static short int @@ -719,7 +719,7 @@ pssl_pstream_cast(struct pstream *pstream) } static int -pssl_open(const char *name UNUSED, char *suffix, struct pstream **pstreamp) +pssl_open(const char *name OVS_UNUSED, char *suffix, struct pstream **pstreamp) { struct pssl_pstream *pssl; struct sockaddr_in sin; @@ -732,7 +732,7 @@ pssl_open(const char *name UNUSED, char *suffix, struct pstream **pstreamp) return retval; } - fd = inet_open_passive(SOCK_STREAM, suffix, OFP_SSL_PORT, NULL); + fd = inet_open_passive(SOCK_STREAM, suffix, OFP_SSL_PORT, &sin); if (fd < 0) { return -fd; } @@ -855,7 +855,7 @@ do_ssl_init(void) } static DH * -tmp_dh_callback(SSL *ssl UNUSED, int is_export UNUSED, int keylength) +tmp_dh_callback(SSL *ssl OVS_UNUSED, int is_export OVS_UNUSED, int keylength) { struct dh { int keylength; @@ -1074,6 +1074,7 @@ stream_ssl_set_ca_cert_file(const char *file_name, bool bootstrap) } X509_free(certs[i]); } + free(certs); /* Set up CAs for OpenSSL to trust in verifying the peer's * certificate. */