From 45dd28e6a1ce8bcd42cc7d547c223b05ffebff9b Mon Sep 17 00:00:00 2001 From: Rick Mark Date: Thu, 7 May 2020 09:42:23 -0700 Subject: Do not perform preflight on T2 devices --- src/preflight.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/preflight.c') 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 @@ #include "client.h" #include "conf.h" #include "log.h" +#include "usb.h" + +extern int no_preflight; #ifdef HAVE_LIBIMOBILEDEVICE #ifndef HAVE_ENUM_IDEVICE_CONNECTION_TYPE @@ -270,7 +273,7 @@ retry: "com.apple.mobile.lockdown.request_pair", "com.apple.mobile.lockdown.request_host_buid", NULL - }; + }; np_observe_notifications(np, spec); /* TODO send notification to user's desktop */ @@ -353,6 +356,11 @@ void preflight_device_remove_cb(void *data) void preflight_worker_device_add(struct device_info* info) { + if (info->pid == PID_APPLE_T2_COPROCESSOR || no_preflight == 1) { + client_device_add(info); + return; + } + #ifdef HAVE_LIBIMOBILEDEVICE struct device_info *infocopy = (struct device_info*)malloc(sizeof(struct device_info)); -- cgit v1.1-32-gdbae