diff options
author | 2020-05-07 09:42:23 -0700 | |
---|---|---|
committer | 2020-05-07 09:42:23 -0700 | |
commit | 45dd28e6a1ce8bcd42cc7d547c223b05ffebff9b (patch) | |
tree | c3b3ef80696c3291950d315aa4e32b78ffad0806 /src/preflight.c | |
parent | 68d4d1c89d462ebbeb3cf51120fe96813377a0f6 (diff) | |
download | usbmuxd-45dd28e6a1ce8bcd42cc7d547c223b05ffebff9b.tar.gz usbmuxd-45dd28e6a1ce8bcd42cc7d547c223b05ffebff9b.tar.bz2 |
Do not perform preflight on T2 devices
Diffstat (limited to 'src/preflight.c')
-rw-r--r-- | src/preflight.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/preflight.c b/src/preflight.c index c7cfa50..820f3fc 100644 --- a/src/preflight.c +++ b/src/preflight.c | |||
@@ -41,6 +41,9 @@ | |||
41 | #include "client.h" | 41 | #include "client.h" |
42 | #include "conf.h" | 42 | #include "conf.h" |
43 | #include "log.h" | 43 | #include "log.h" |
44 | #include "usb.h" | ||
45 | |||
46 | extern int no_preflight; | ||
44 | 47 | ||
45 | #ifdef HAVE_LIBIMOBILEDEVICE | 48 | #ifdef HAVE_LIBIMOBILEDEVICE |
46 | #ifndef HAVE_ENUM_IDEVICE_CONNECTION_TYPE | 49 | #ifndef HAVE_ENUM_IDEVICE_CONNECTION_TYPE |
@@ -270,7 +273,7 @@ retry: | |||
270 | "com.apple.mobile.lockdown.request_pair", | 273 | "com.apple.mobile.lockdown.request_pair", |
271 | "com.apple.mobile.lockdown.request_host_buid", | 274 | "com.apple.mobile.lockdown.request_host_buid", |
272 | NULL | 275 | NULL |
273 | }; | 276 | }; |
274 | np_observe_notifications(np, spec); | 277 | np_observe_notifications(np, spec); |
275 | 278 | ||
276 | /* TODO send notification to user's desktop */ | 279 | /* TODO send notification to user's desktop */ |
@@ -353,6 +356,11 @@ void preflight_device_remove_cb(void *data) | |||
353 | 356 | ||
354 | void preflight_worker_device_add(struct device_info* info) | 357 | void preflight_worker_device_add(struct device_info* info) |
355 | { | 358 | { |
359 | if (info->pid == PID_APPLE_T2_COPROCESSOR || no_preflight == 1) { | ||
360 | client_device_add(info); | ||
361 | return; | ||
362 | } | ||
363 | |||
356 | #ifdef HAVE_LIBIMOBILEDEVICE | 364 | #ifdef HAVE_LIBIMOBILEDEVICE |
357 | struct device_info *infocopy = (struct device_info*)malloc(sizeof(struct device_info)); | 365 | struct device_info *infocopy = (struct device_info*)malloc(sizeof(struct device_info)); |
358 | 366 | ||