summaryrefslogtreecommitdiffstats
path: root/newlib/libc/string/strerror.c
diff options
context:
space:
mode:
Diffstat (limited to 'newlib/libc/string/strerror.c')
-rw-r--r--newlib/libc/string/strerror.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/newlib/libc/string/strerror.c b/newlib/libc/string/strerror.c
index 209eeb9cc..8bea4b768 100644
--- a/newlib/libc/string/strerror.c
+++ b/newlib/libc/string/strerror.c
@@ -736,7 +736,7 @@ _DEFUN (strerror, (errnum),
error = "Socket is already connected";
break;
#endif
-#ifdef EOPNOTSUPP
+#if defined(EOPNOTSUPP) && (!defined(ENOTSUP) || (ENOTSUP != EOPNOTSUPP))
case EOPNOTSUPP:
error = "Operation not supported on socket";
break;