diff options
| author | 2020-06-05 20:50:34 +0200 | |
|---|---|---|
| committer | 2020-06-05 20:50:34 +0200 | |
| commit | 489a673aeeef4706af3986d41c24ab434e77d7d5 (patch) | |
| tree | 123022859215220cf7f10a483d02bffdf157a0ce /tools/idevicesyslog.c | |
| parent | 3aa4e243faa8198550cb2851cb6f0b9cbb293812 (diff) | |
| download | libimobiledevice-489a673aeeef4706af3986d41c24ab434e77d7d5.tar.gz libimobiledevice-489a673aeeef4706af3986d41c24ab434e77d7d5.tar.bz2 | |
tools: Unify --network command line switch and add it where missing
Diffstat (limited to 'tools/idevicesyslog.c')
| -rw-r--r-- | tools/idevicesyslog.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/idevicesyslog.c b/tools/idevicesyslog.c index acbcd74..0eed138 100644 --- a/tools/idevicesyslog.c +++ b/tools/idevicesyslog.c | |||
| @@ -69,7 +69,7 @@ static syslog_relay_client_t syslog = NULL; | |||
| 69 | 69 | ||
| 70 | static const char QUIET_FILTER[] = "CircleJoinRequested|CommCenter|HeuristicInterpreter|MobileMail|PowerUIAgent|ProtectedCloudKeySyncing|SpringBoard|UserEventAgent|WirelessRadioManagerd|accessoryd|accountsd|aggregated|analyticsd|appstored|apsd|assetsd|assistant_service|backboardd|biometrickitd|bluetoothd|calaccessd|callservicesd|cloudd|com.apple.Safari.SafeBrowsing.Service|contextstored|corecaptured|coreduetd|corespeechd|cdpd|dasd|dataaccessd|distnoted|dprivacyd|duetexpertd|findmydeviced|fmfd|fmflocatord|gpsd|healthd|homed|identityservicesd|imagent|itunescloudd|itunesstored|kernel|locationd|maild|mDNSResponder|mediaremoted|mediaserverd|mobileassetd|nanoregistryd|nanotimekitcompaniond|navd|nsurlsessiond|passd|pasted|photoanalysisd|powerd|powerlogHelperd|ptpd|rapportd|remindd|routined|runningboardd|searchd|sharingd|suggestd|symptomsd|timed|thermalmonitord|useractivityd|vmd|wifid|wirelessproxd"; | 70 | static const char QUIET_FILTER[] = "CircleJoinRequested|CommCenter|HeuristicInterpreter|MobileMail|PowerUIAgent|ProtectedCloudKeySyncing|SpringBoard|UserEventAgent|WirelessRadioManagerd|accessoryd|accountsd|aggregated|analyticsd|appstored|apsd|assetsd|assistant_service|backboardd|biometrickitd|bluetoothd|calaccessd|callservicesd|cloudd|com.apple.Safari.SafeBrowsing.Service|contextstored|corecaptured|coreduetd|corespeechd|cdpd|dasd|dataaccessd|distnoted|dprivacyd|duetexpertd|findmydeviced|fmfd|fmflocatord|gpsd|healthd|homed|identityservicesd|imagent|itunescloudd|itunesstored|kernel|locationd|maild|mDNSResponder|mediaremoted|mediaserverd|mobileassetd|nanoregistryd|nanotimekitcompaniond|navd|nsurlsessiond|passd|pasted|photoanalysisd|powerd|powerlogHelperd|ptpd|rapportd|remindd|routined|runningboardd|searchd|sharingd|suggestd|symptomsd|timed|thermalmonitord|useractivityd|vmd|wifid|wirelessproxd"; |
| 71 | 71 | ||
| 72 | enum idevice_options lookup_opts = IDEVICE_LOOKUP_USBMUX | IDEVICE_LOOKUP_NETWORK; | 72 | static int use_network = 0; |
| 73 | 73 | ||
| 74 | static char *line = NULL; | 74 | static char *line = NULL; |
| 75 | static int line_buffer_size = 0; | 75 | static int line_buffer_size = 0; |
| @@ -403,7 +403,7 @@ static void syslog_callback(char c, void *user_data) | |||
| 403 | 403 | ||
| 404 | static int start_logging(void) | 404 | static int start_logging(void) |
| 405 | { | 405 | { |
| 406 | idevice_error_t ret = idevice_new_with_options(&device, udid, lookup_opts); | 406 | idevice_error_t ret = idevice_new_with_options(&device, udid, (use_network) ? IDEVICE_LOOKUP_NETWORK : IDEVICE_LOOKUP_USBMUX); |
| 407 | if (ret != IDEVICE_E_SUCCESS) { | 407 | if (ret != IDEVICE_E_SUCCESS) { |
| 408 | fprintf(stderr, "Device with udid %s not found!?\n", udid); | 408 | fprintf(stderr, "Device with udid %s not found!?\n", udid); |
| 409 | return -1; | 409 | return -1; |
| @@ -526,7 +526,7 @@ static void print_usage(int argc, char **argv, int is_error) | |||
| 526 | "\n" \ | 526 | "\n" \ |
| 527 | "OPTIONS:\n" \ | 527 | "OPTIONS:\n" \ |
| 528 | " -u, --udid UDID target specific device by UDID\n" \ | 528 | " -u, --udid UDID target specific device by UDID\n" \ |
| 529 | " -n, --network connect to network device even if available via USB\n" \ | 529 | " -n, --network connect to network device\n" \ |
| 530 | " -x, --exit exit when device disconnects\n" \ | 530 | " -x, --exit exit when device disconnects\n" \ |
| 531 | " -h, --help prints usage information\n" \ | 531 | " -h, --help prints usage information\n" \ |
| 532 | " -d, --debug enable communication debugging\n" \ | 532 | " -d, --debug enable communication debugging\n" \ |
| @@ -610,7 +610,7 @@ int main(int argc, char *argv[]) | |||
| 610 | udid = strdup(optarg); | 610 | udid = strdup(optarg); |
| 611 | break; | 611 | break; |
| 612 | case 'n': | 612 | case 'n': |
| 613 | lookup_opts |= IDEVICE_LOOKUP_PREFER_NETWORK; | 613 | use_network = 1; |
| 614 | break; | 614 | break; |
| 615 | case 'q': | 615 | case 'q': |
| 616 | exclude_filter++; | 616 | exclude_filter++; |
