From 68f4b7886317f7731f89b3bfda6e014f7e5b03f4 Mon Sep 17 00:00:00 2001 From: Andrei Emeltchenko Date: Fri, 20 Dec 2013 14:09:52 +0200 Subject: [PATCH] android/tester: Make code consistent using < 0 comparison --- android/android-tester.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/android/android-tester.c b/android/android-tester.c index 25b0444a9..d1086dfcf 100644 --- a/android/android-tester.c +++ b/android/android-tester.c @@ -1199,7 +1199,7 @@ static void test_generic_listen(const void *test_data) } /* Check that file descriptor is valid */ - if (status == BT_STATUS_SUCCESS && fcntl(sock_fd, F_GETFD) == -1) { + if (status == BT_STATUS_SUCCESS && fcntl(sock_fd, F_GETFD) < 0) { tester_test_failed(); return; } @@ -1332,7 +1332,7 @@ static void test_generic_connect(const void *test_data) } /* Check that file descriptor is valid */ - if (status == BT_STATUS_SUCCESS && fcntl(sock_fd, F_GETFD) == -1) { + if (status == BT_STATUS_SUCCESS && fcntl(sock_fd, F_GETFD) < 0) { tester_test_failed(); return; } @@ -1467,7 +1467,7 @@ static void test_socket_real_connect(const void *test_data) } /* Check that file descriptor is valid */ - if (status == BT_STATUS_SUCCESS && fcntl(sock_fd, F_GETFD) == -1) { + if (status == BT_STATUS_SUCCESS && fcntl(sock_fd, F_GETFD) < 0) { tester_test_failed(); return; } -- 2.47.3