diff options
author | Nikias Bassen | 2020-05-21 04:31:00 +0200 |
---|---|---|
committer | Nikias Bassen | 2020-05-21 04:31:00 +0200 |
commit | 8036f3f227211fdff18cbbf85ab84f45a44c5add (patch) | |
tree | b7cfcdcd02dd31e5483fb338c32839d20543d646 /src | |
parent | d1cb6bfef6ac8fb08472ac5f1fac93895084371c (diff) | |
download | idevicerestore-8036f3f227211fdff18cbbf85ab84f45a44c5add.tar.gz idevicerestore-8036f3f227211fdff18cbbf85ab84f45a44c5add.tar.bz2 |
Ignore non-usbmux (i.e. wifi sync) devices in device event callback
Diffstat (limited to 'src')
-rw-r--r-- | src/idevicerestore.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/idevicerestore.c b/src/idevicerestore.c index f1a7a56..2c5f88c 100644 --- a/src/idevicerestore.c +++ b/src/idevicerestore.c @@ -215,6 +215,12 @@ static int compare_versions(const char *s_ver1, const char *s_ver2) static void idevice_event_cb(const idevice_event_t *event, void *userdata) { struct idevicerestore_client_t *client = (struct idevicerestore_client_t*)userdata; +#ifdef HAVE_ENUM_IDEVICE_CONNECTION_TYPE + if (event->conn_type != CONNECTION_USBMUXD) { + // ignore everything but devices connected through USB + return; + } +#endif if (event->event == IDEVICE_DEVICE_ADD) { if (client->ignore_device_add_events) { return; |