From 2565e5307b0d75d01abe4b7d6f2393f8f25a2778 Mon Sep 17 00:00:00 2001 From: Beman Dawes Date: Wed, 26 May 2010 00:38:07 +0000 Subject: [PATCH] Fix #3994, error values on some Broadcom chips [SVN r62222] --- src/error_code.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/error_code.cpp b/src/error_code.cpp index fa2cb0b..c40eec3 100644 --- a/src/error_code.cpp +++ b/src/error_code.cpp @@ -221,7 +221,9 @@ namespace # if ENOTEMPTY != EEXIST // AIX treats ENOTEMPTY and EEXIST as the same value case ENOTEMPTY: return make_error_condition( directory_not_empty ); # endif // ENOTEMPTY != EEXIST - case ENOTRECOVERABLE: return make_error_condition( state_not_recoverable ); + # if ENOTRECOVERABLE != ECONNRESET // the same on some Broadcom chips + case ENOTRECOVERABLE: return make_error_condition( state_not_recoverable ); + # endif // ENOTRECOVERABLE != ECONNRESET case ENOTSOCK: return make_error_condition( not_a_socket ); case ENOTSUP: return make_error_condition( not_supported ); case ENOTTY: return make_error_condition( inappropriate_io_control_operation ); @@ -230,7 +232,9 @@ namespace case EOPNOTSUPP: return make_error_condition( operation_not_supported ); # endif // EOPNOTSUPP != ENOTSUP case EOVERFLOW: return make_error_condition( value_too_large ); - case EOWNERDEAD: return make_error_condition( owner_dead ); + # if EOWNERDEAD != ECONNABORTED // the same on some Broadcom chips + case EOWNERDEAD: return make_error_condition( owner_dead ); + # endif // EOWNERDEAD != ECONNABORTED case EPERM: return make_error_condition( operation_not_permitted ); case EPIPE: return make_error_condition( broken_pipe ); case EPROTO: return make_error_condition( protocol_error );