EINTR is handled by adb_read/unix_read and friends.
No need to clutter the code with cases that won't happen.
Change-Id: I47c5a2e6170f902d2618719f44492234a4869567
diff --git a/adb/transport.cpp b/adb/transport.cpp
index ea673f2..afdab86 100644
--- a/adb/transport.cpp
+++ b/adb/transport.cpp
@@ -140,8 +140,7 @@
len -= r;
p += r;
} else {
- D("%s: read_packet (fd=%d), error ret=%d errno=%d: %s\n", name, fd, r, errno, strerror(errno));
- if((r < 0) && (errno == EINTR)) continue;
+ D("%s: read_packet (fd=%d), error ret=%d: %s\n", name, fd, r, strerror(errno));
return -1;
}
}
@@ -171,8 +170,7 @@
len -= r;
p += r;
} else {
- D("%s: write_packet (fd=%d) error ret=%d errno=%d: %s\n", name, fd, r, errno, strerror(errno));
- if((r < 0) && (errno == EINTR)) continue;
+ D("%s: write_packet (fd=%d) error ret=%d: %s\n", name, fd, r, strerror(errno));
return -1;
}
}
@@ -489,9 +487,7 @@
len -= r;
p += r;
} else {
- if((r < 0) && (errno == EINTR)) continue;
- D("transport_read_action: on fd %d, error %d: %s\n",
- fd, errno, strerror(errno));
+ D("transport_read_action: on fd %d: %s\n", fd, strerror(errno));
return -1;
}
}
@@ -511,9 +507,7 @@
len -= r;
p += r;
} else {
- if((r < 0) && (errno == EINTR)) continue;
- D("transport_write_action: on fd %d, error %d: %s\n",
- fd, errno, strerror(errno));
+ D("transport_write_action: on fd %d: %s\n", fd, strerror(errno));
return -1;
}
}