aboutsummaryrefslogtreecommitdiffstats
path: root/extcap
diff options
context:
space:
mode:
authorAlexis La Goutte <alexis.lagoutte@gmail.com>2016-02-11 20:53:29 +0100
committerRoland Knall <rknall@gmail.com>2016-02-13 14:46:27 +0000
commit137358a404d0255a6976dea22b8705b54583c8d7 (patch)
treec2393cd3fa6c492b71ddc0a0981dca7a3fd755c3 /extcap
parentb550c33d4a95f778cf56154fd0efc96db29b0127 (diff)
androiddump: fix logical ‘or’ of equal expressions [-Werror=logical-op] found by gcc6
EAGAIN and EWOULDBLOCK is the same value (now) http://www-numi.fnal.gov/offline_software/srt_public_context/WebDocs/Errors/unix_system_errors.html Change-Id: Ia8101d05194910f306e8439507ae5bde3ccd00ce Reviewed-on: https://code.wireshark.org/review/13905 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com> Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Roland Knall <rknall@gmail.com>
Diffstat (limited to 'extcap')
-rw-r--r--extcap/androiddump.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/extcap/androiddump.c b/extcap/androiddump.c
index 92778fb30d..45f03c8d26 100644
--- a/extcap/androiddump.c
+++ b/extcap/androiddump.c
@@ -1058,7 +1058,7 @@ static int capture_android_bluetooth_hcidump(char *interface, char *fifo,
errno = 0;
length = recv(sock, data + used_buffer_length, (int)(PACKET_LENGTH - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -1123,7 +1123,7 @@ static int capture_android_bluetooth_hcidump(char *interface, char *fifo,
errno = 0;
length = recv(sock, data + used_buffer_length, (int)(PACKET_LENGTH - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -1155,7 +1155,7 @@ static int capture_android_bluetooth_hcidump(char *interface, char *fifo,
while (endless_loop) {
errno = 0;
length = recv(sock, data + used_buffer_length, (int)(PACKET_LENGTH - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -1462,7 +1462,7 @@ static int capture_android_bluetooth_external_parser(char *interface,
while (endless_loop) {
errno = 0;
length = recv(sock, buffer + used_buffer_length, (int)(PACKET_LENGTH - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -1679,7 +1679,7 @@ static int capture_android_bluetooth_btsnoop_net(char *interface, char *fifo,
errno = 0;
length = recv(sock, packet + used_buffer_length + sizeof(own_pcap_bluetooth_h4_header),
(int)(PACKET_LENGTH - sizeof(own_pcap_bluetooth_h4_header) - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -1850,7 +1850,7 @@ static int capture_android_logcat_text(char *interface, char *fifo,
while (endless_loop) {
errno = 0;
length = recv(sock, packet + exported_pdu_headers_size + used_buffer_length, (int)(PACKET_LENGTH - exported_pdu_headers_size - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -2029,7 +2029,7 @@ static int capture_android_logcat(char *interface, char *fifo,
while (endless_loop) {
errno = 0;
length = recv(sock, packet + exported_pdu_headers_size + used_buffer_length, (int)(PACKET_LENGTH - exported_pdu_headers_size - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) continue;
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) continue;
else if (errno != 0) {
if (verbose)
printf("ERROR capture: %s\n", strerror(errno));
@@ -2254,7 +2254,7 @@ static int capture_android_wifi_tcpdump(char *interface, char *fifo,
char *i_position;
errno = 0;
length = recv(sock, data + used_buffer_length, (int)(PACKET_LENGTH - used_buffer_length), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK)
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK))
continue;
else if (errno != 0) {
if (verbose)
@@ -2366,7 +2366,7 @@ static int capture_android_wifi_tcpdump(char *interface, char *fifo,
while (endless_loop) {
errno = 0;
length = recv(sock, data + used_buffer_length, (int)(PACKET_LENGTH -(used_buffer_length + filter_buffer_length)), 0);
- if (errno == EAGAIN || errno == EWOULDBLOCK) {
+ if (errno == EAGAIN || (EWOULDBLOCK != EAGAIN && errno == EWOULDBLOCK)) {
continue;
}
else if (errno != 0) {