summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/idevice.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/idevice.c b/src/idevice.c
index 47c9ab4..c71c49b 100644
--- a/src/idevice.c
+++ b/src/idevice.c
@@ -527,7 +527,10 @@ static idevice_error_t internal_connection_send(idevice_connection_t connection,
}
if (connection->type == CONNECTION_USBMUXD) {
- int res = usbmuxd_send((int)(long)connection->data, data, len, sent_bytes);
+ int res;
+ do {
+ res = usbmuxd_send((int)(long)connection->data, data, len, sent_bytes);
+ } while (res == -EAGAIN);
if (res < 0) {
debug_info("ERROR: usbmuxd_send returned %d (%s)", res, strerror(-res));
return IDEVICE_E_UNKNOWN_ERROR;