Merge change I5dbd1994 into eclair
* changes: Fix rfcomm socket connect return code.
This commit is contained in:
@@ -396,7 +396,7 @@ static jint waitForAsyncConnectNative(JNIEnv *env, jobject obj,
|
|||||||
LOGE("select() on RFCOMM socket: %s (%d)",
|
LOGE("select() on RFCOMM socket: %s (%d)",
|
||||||
strerror(errno),
|
strerror(errno),
|
||||||
errno);
|
errno);
|
||||||
return -1;
|
return -errno;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -429,7 +429,7 @@ static jint waitForAsyncConnectNative(JNIEnv *env, jobject obj,
|
|||||||
fcntl(nat->rfcomm_sock, F_SETFL, nat->rfcomm_sock_flags);
|
fcntl(nat->rfcomm_sock, F_SETFL, nat->rfcomm_sock_flags);
|
||||||
close(nat->rfcomm_sock);
|
close(nat->rfcomm_sock);
|
||||||
nat->rfcomm_sock = -1;
|
nat->rfcomm_sock = -1;
|
||||||
return -1;
|
return -errno;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* Restore the blocking properties of the socket. */
|
/* Restore the blocking properties of the socket. */
|
||||||
|
|||||||
Reference in New Issue
Block a user