summaryrefslogtreecommitdiffstats
path: root/x-net/src
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2010-02-03 12:42:27 -0800
committerElliott Hughes <enh@google.com>2010-02-03 12:42:27 -0800
commit0a807e587935a92811a2f3703caab87115363030 (patch)
treeb92c5f4063be0cc4eb44bbea0f0f025585064b8f /x-net/src
parent4d4ca58e669c83e2c4e0a0d49d3d854f6883dc84 (diff)
downloadlibcore-0a807e587935a92811a2f3703caab87115363030.zip
libcore-0a807e587935a92811a2f3703caab87115363030.tar.gz
libcore-0a807e587935a92811a2f3703caab87115363030.tar.bz2
Fix two compiler warnings.
Signed/unsigned comparison in "File.cpp", and && and || without parentheses in "OpenSSLSocketImpl.cpp". There's another signed/unsigned comparison in "ifaddrs-android.h" but that isn't fixable (http://b/2417132), which is going to stand in the way of turning on -Werror.
Diffstat (limited to 'x-net/src')
-rw-r--r--x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp b/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp
index a3c86d6..20bb8a5 100644
--- a/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp
+++ b/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp
@@ -1327,12 +1327,12 @@ static void org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl_accept(JNIEn
*/
int sslErrorCode = SSL_get_error(ssl, ret);
if (sslErrorCode == SSL_ERROR_NONE ||
- sslErrorCode == SSL_ERROR_SYSCALL && errno == 0) {
- throwIOExceptionStr(env, "Connection closed by peer");
+ (sslErrorCode == SSL_ERROR_SYSCALL && errno == 0)) {
+ throwIOExceptionStr(env, "Connection closed by peer");
} else {
- throwIOExceptionWithSslErrors(env, ret, sslErrorCode,
- "Trouble accepting connection");
- }
+ throwIOExceptionWithSslErrors(env, ret, sslErrorCode,
+ "Trouble accepting connection");
+ }
free_ssl(env, object);
return;
} else if (ret < 0) {