diff options
author | matthew <> | 2014-04-13 23:58:18 +0000 |
---|---|---|
committer | matthew <> | 2014-04-13 23:58:18 +0000 |
commit | 26762a2077f0e4a62bb5a0773f0542de4046618f (patch) | |
tree | 835f053585fbe510fa3f8d525e11695edf779f56 /src | |
parent | 5389926124ee089503d54f4ca8b9a3c01ebf3397 (diff) | |
download | openbsd-26762a2077f0e4a62bb5a0773f0542de4046618f.tar.gz openbsd-26762a2077f0e4a62bb5a0773f0542de4046618f.tar.bz2 openbsd-26762a2077f0e4a62bb5a0773f0542de4046618f.zip |
Use shutdown(s, SHUT_RDWR) instead of shutdown(s, 2).
ok beck deraadt
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/libcrypto/bio/bss_acpt.c | 2 | ||||
-rw-r--r-- | src/lib/libcrypto/bio/bss_conn.c | 2 | ||||
-rw-r--r-- | src/lib/libssl/src/crypto/bio/bss_acpt.c | 2 | ||||
-rw-r--r-- | src/lib/libssl/src/crypto/bio/bss_conn.c | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/libcrypto/bio/bss_acpt.c b/src/lib/libcrypto/bio/bss_acpt.c index 5507a53a2f..04bfb6fb9d 100644 --- a/src/lib/libcrypto/bio/bss_acpt.c +++ b/src/lib/libcrypto/bio/bss_acpt.c | |||
@@ -172,7 +172,7 @@ static void acpt_close_socket(BIO *bio) | |||
172 | c=(BIO_ACCEPT *)bio->ptr; | 172 | c=(BIO_ACCEPT *)bio->ptr; |
173 | if (c->accept_sock != -1) | 173 | if (c->accept_sock != -1) |
174 | { | 174 | { |
175 | shutdown(c->accept_sock,2); | 175 | shutdown(c->accept_sock, SHUT_RDWR); |
176 | close(c->accept_sock); | 176 | close(c->accept_sock); |
177 | c->accept_sock=-1; | 177 | c->accept_sock=-1; |
178 | bio->num=-1; | 178 | bio->num=-1; |
diff --git a/src/lib/libcrypto/bio/bss_conn.c b/src/lib/libcrypto/bio/bss_conn.c index bdf540030c..42ddf1f4aa 100644 --- a/src/lib/libcrypto/bio/bss_conn.c +++ b/src/lib/libcrypto/bio/bss_conn.c | |||
@@ -375,7 +375,7 @@ static void conn_close_socket(BIO *bio) | |||
375 | { | 375 | { |
376 | /* Only do a shutdown if things were established */ | 376 | /* Only do a shutdown if things were established */ |
377 | if (c->state == BIO_CONN_S_OK) | 377 | if (c->state == BIO_CONN_S_OK) |
378 | shutdown(bio->num,2); | 378 | shutdown(bio->num, SHUT_RDWR); |
379 | close(bio->num); | 379 | close(bio->num); |
380 | bio->num=-1; | 380 | bio->num=-1; |
381 | } | 381 | } |
diff --git a/src/lib/libssl/src/crypto/bio/bss_acpt.c b/src/lib/libssl/src/crypto/bio/bss_acpt.c index 5507a53a2f..04bfb6fb9d 100644 --- a/src/lib/libssl/src/crypto/bio/bss_acpt.c +++ b/src/lib/libssl/src/crypto/bio/bss_acpt.c | |||
@@ -172,7 +172,7 @@ static void acpt_close_socket(BIO *bio) | |||
172 | c=(BIO_ACCEPT *)bio->ptr; | 172 | c=(BIO_ACCEPT *)bio->ptr; |
173 | if (c->accept_sock != -1) | 173 | if (c->accept_sock != -1) |
174 | { | 174 | { |
175 | shutdown(c->accept_sock,2); | 175 | shutdown(c->accept_sock, SHUT_RDWR); |
176 | close(c->accept_sock); | 176 | close(c->accept_sock); |
177 | c->accept_sock=-1; | 177 | c->accept_sock=-1; |
178 | bio->num=-1; | 178 | bio->num=-1; |
diff --git a/src/lib/libssl/src/crypto/bio/bss_conn.c b/src/lib/libssl/src/crypto/bio/bss_conn.c index bdf540030c..42ddf1f4aa 100644 --- a/src/lib/libssl/src/crypto/bio/bss_conn.c +++ b/src/lib/libssl/src/crypto/bio/bss_conn.c | |||
@@ -375,7 +375,7 @@ static void conn_close_socket(BIO *bio) | |||
375 | { | 375 | { |
376 | /* Only do a shutdown if things were established */ | 376 | /* Only do a shutdown if things were established */ |
377 | if (c->state == BIO_CONN_S_OK) | 377 | if (c->state == BIO_CONN_S_OK) |
378 | shutdown(bio->num,2); | 378 | shutdown(bio->num, SHUT_RDWR); |
379 | close(bio->num); | 379 | close(bio->num); |
380 | bio->num=-1; | 380 | bio->num=-1; |
381 | } | 381 | } |