summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjsing <jsing@openbsd.org>2014-04-16 13:01:09 +0000
committerjsing <jsing@openbsd.org>2014-04-16 13:01:09 +0000
commit316efac5a44d4de39cde394886fb6cd2e1a99706 (patch)
tree05a2688ada33eeb3b4a56526b363069306ac42f5
parentunbreak install; /usr/share/man/man3/EVP_PKEY_print_private.3 should link to (diff)
downloadwireguard-openbsd-316efac5a44d4de39cde394886fb6cd2e1a99706.tar.xz
wireguard-openbsd-316efac5a44d4de39cde394886fb6cd2e1a99706.zip
Clean up non-fatal error handling - we know which error numbers we have
defined. ok miod@ beck@
-rw-r--r--lib/libcrypto/bio/bss_dgram.c30
-rw-r--r--lib/libcrypto/bio/bss_fd.c32
-rw-r--r--lib/libcrypto/bio/bss_sock.c43
-rw-r--r--lib/libssl/src/crypto/bio/bss_dgram.c30
-rw-r--r--lib/libssl/src/crypto/bio/bss_fd.c32
-rw-r--r--lib/libssl/src/crypto/bio/bss_sock.c43
6 files changed, 0 insertions, 210 deletions
diff --git a/lib/libcrypto/bio/bss_dgram.c b/lib/libcrypto/bio/bss_dgram.c
index 328bab9ce3c..9219fffc8d0 100644
--- a/lib/libcrypto/bio/bss_dgram.c
+++ b/lib/libcrypto/bio/bss_dgram.c
@@ -1687,41 +1687,11 @@ int
BIO_dgram_non_fatal_error(int err)
{
switch (err) {
-
-#ifdef EWOULDBLOCK
-# ifdef WSAEWOULDBLOCK
-# if WSAEWOULDBLOCK != EWOULDBLOCK
- case EWOULDBLOCK:
-# endif
-# else
- case EWOULDBLOCK:
-# endif
-#endif
-
-#ifdef EINTR
case EINTR:
-#endif
-
-#ifdef EAGAIN
-#if EWOULDBLOCK != EAGAIN
case EAGAIN:
-# endif
-#endif
-
-#ifdef EPROTO
- case EPROTO:
-#endif
-
-#ifdef EINPROGRESS
case EINPROGRESS:
-#endif
-
-#ifdef EALREADY
case EALREADY:
-#endif
-
return (1);
- /* break; */
default:
break;
}
diff --git a/lib/libcrypto/bio/bss_fd.c b/lib/libcrypto/bio/bss_fd.c
index 86757154e8a..c0e7f08fbb5 100644
--- a/lib/libcrypto/bio/bss_fd.c
+++ b/lib/libcrypto/bio/bss_fd.c
@@ -270,44 +270,12 @@ int
BIO_fd_non_fatal_error(int err)
{
switch (err) {
-
-#ifdef EWOULDBLOCK
-# ifdef WSAEWOULDBLOCK
-# if WSAEWOULDBLOCK != EWOULDBLOCK
- case EWOULDBLOCK:
-# endif
-# else
- case EWOULDBLOCK:
-# endif
-#endif
-
-#if defined(ENOTCONN)
case ENOTCONN:
-#endif
-
-#ifdef EINTR
case EINTR:
-#endif
-
-#ifdef EAGAIN
-#if EWOULDBLOCK != EAGAIN
case EAGAIN:
-# endif
-#endif
-
-#ifdef EPROTO
- case EPROTO:
-#endif
-
-#ifdef EINPROGRESS
case EINPROGRESS:
-#endif
-
-#ifdef EALREADY
case EALREADY:
-#endif
return (1);
- /* break; */
default:
break;
}
diff --git a/lib/libcrypto/bio/bss_sock.c b/lib/libcrypto/bio/bss_sock.c
index 30640d8f962..c05b8d37f1d 100644
--- a/lib/libcrypto/bio/bss_sock.c
+++ b/lib/libcrypto/bio/bss_sock.c
@@ -233,55 +233,12 @@ int
BIO_sock_non_fatal_error(int err)
{
switch (err) {
-#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_NETWARE)
-# if defined(WSAEWOULDBLOCK)
- case WSAEWOULDBLOCK:
-# endif
-
-# if 0 /* This appears to always be an error */
-# if defined(WSAENOTCONN)
- case WSAENOTCONN:
-# endif
-# endif
-#endif
-
-#ifdef EWOULDBLOCK
-# ifdef WSAEWOULDBLOCK
-# if WSAEWOULDBLOCK != EWOULDBLOCK
- case EWOULDBLOCK:
-# endif
-# else
- case EWOULDBLOCK:
-# endif
-#endif
-
-#if defined(ENOTCONN)
case ENOTCONN:
-#endif
-
-#ifdef EINTR
case EINTR:
-#endif
-
-#ifdef EAGAIN
-# if EWOULDBLOCK != EAGAIN
case EAGAIN:
-# endif
-#endif
-
-#ifdef EPROTO
- case EPROTO:
-#endif
-
-#ifdef EINPROGRESS
case EINPROGRESS:
-#endif
-
-#ifdef EALREADY
case EALREADY:
-#endif
return (1);
- /* break; */
default:
break;
}
diff --git a/lib/libssl/src/crypto/bio/bss_dgram.c b/lib/libssl/src/crypto/bio/bss_dgram.c
index 328bab9ce3c..9219fffc8d0 100644
--- a/lib/libssl/src/crypto/bio/bss_dgram.c
+++ b/lib/libssl/src/crypto/bio/bss_dgram.c
@@ -1687,41 +1687,11 @@ int
BIO_dgram_non_fatal_error(int err)
{
switch (err) {
-
-#ifdef EWOULDBLOCK
-# ifdef WSAEWOULDBLOCK
-# if WSAEWOULDBLOCK != EWOULDBLOCK
- case EWOULDBLOCK:
-# endif
-# else
- case EWOULDBLOCK:
-# endif
-#endif
-
-#ifdef EINTR
case EINTR:
-#endif
-
-#ifdef EAGAIN
-#if EWOULDBLOCK != EAGAIN
case EAGAIN:
-# endif
-#endif
-
-#ifdef EPROTO
- case EPROTO:
-#endif
-
-#ifdef EINPROGRESS
case EINPROGRESS:
-#endif
-
-#ifdef EALREADY
case EALREADY:
-#endif
-
return (1);
- /* break; */
default:
break;
}
diff --git a/lib/libssl/src/crypto/bio/bss_fd.c b/lib/libssl/src/crypto/bio/bss_fd.c
index 86757154e8a..c0e7f08fbb5 100644
--- a/lib/libssl/src/crypto/bio/bss_fd.c
+++ b/lib/libssl/src/crypto/bio/bss_fd.c
@@ -270,44 +270,12 @@ int
BIO_fd_non_fatal_error(int err)
{
switch (err) {
-
-#ifdef EWOULDBLOCK
-# ifdef WSAEWOULDBLOCK
-# if WSAEWOULDBLOCK != EWOULDBLOCK
- case EWOULDBLOCK:
-# endif
-# else
- case EWOULDBLOCK:
-# endif
-#endif
-
-#if defined(ENOTCONN)
case ENOTCONN:
-#endif
-
-#ifdef EINTR
case EINTR:
-#endif
-
-#ifdef EAGAIN
-#if EWOULDBLOCK != EAGAIN
case EAGAIN:
-# endif
-#endif
-
-#ifdef EPROTO
- case EPROTO:
-#endif
-
-#ifdef EINPROGRESS
case EINPROGRESS:
-#endif
-
-#ifdef EALREADY
case EALREADY:
-#endif
return (1);
- /* break; */
default:
break;
}
diff --git a/lib/libssl/src/crypto/bio/bss_sock.c b/lib/libssl/src/crypto/bio/bss_sock.c
index 30640d8f962..c05b8d37f1d 100644
--- a/lib/libssl/src/crypto/bio/bss_sock.c
+++ b/lib/libssl/src/crypto/bio/bss_sock.c
@@ -233,55 +233,12 @@ int
BIO_sock_non_fatal_error(int err)
{
switch (err) {
-#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_NETWARE)
-# if defined(WSAEWOULDBLOCK)
- case WSAEWOULDBLOCK:
-# endif
-
-# if 0 /* This appears to always be an error */
-# if defined(WSAENOTCONN)
- case WSAENOTCONN:
-# endif
-# endif
-#endif
-
-#ifdef EWOULDBLOCK
-# ifdef WSAEWOULDBLOCK
-# if WSAEWOULDBLOCK != EWOULDBLOCK
- case EWOULDBLOCK:
-# endif
-# else
- case EWOULDBLOCK:
-# endif
-#endif
-
-#if defined(ENOTCONN)
case ENOTCONN:
-#endif
-
-#ifdef EINTR
case EINTR:
-#endif
-
-#ifdef EAGAIN
-# if EWOULDBLOCK != EAGAIN
case EAGAIN:
-# endif
-#endif
-
-#ifdef EPROTO
- case EPROTO:
-#endif
-
-#ifdef EINPROGRESS
case EINPROGRESS:
-#endif
-
-#ifdef EALREADY
case EALREADY:
-#endif
return (1);
- /* break; */
default:
break;
}