summaryrefslogtreecommitdiffstats
path: root/tools/ideviceprovision.c
diff options
context:
space:
mode:
authorGravatar Nikias Bassen2018-10-01 02:32:51 +0200
committerGravatar Nikias Bassen2018-10-01 02:32:51 +0200
commitb34e3435c21d06b3e5a4e7b5246fb6ddb6641a9f (patch)
tree89b78560cd956b956a03c9b207816d8cb345c37e /tools/ideviceprovision.c
parentf1ee0fd8b2b1dd65c64f5a67e208efc708295caa (diff)
downloadlibimobiledevice-b34e3435c21d06b3e5a4e7b5246fb6ddb6641a9f.tar.gz
libimobiledevice-b34e3435c21d06b3e5a4e7b5246fb6ddb6641a9f.tar.bz2
tools: Remove length check on device UDID arguments to support newer devices
The 40 characters length check on the device UDID made newer devices unusable with the libimobiledevice tools and was actually redundant since an invalid UDID will always fail to resolve. This commit removes the length check alltogether (but makes sure it is not an empty string "").
Diffstat (limited to 'tools/ideviceprovision.c')
-rw-r--r--tools/ideviceprovision.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/ideviceprovision.c b/tools/ideviceprovision.c
index 0bef7e8..f91ce4f 100644
--- a/tools/ideviceprovision.c
+++ b/tools/ideviceprovision.c
@@ -64,7 +64,7 @@ static void print_usage(int argc, char **argv)
64 printf(" \tspecified by FILE.\n\n"); 64 printf(" \tspecified by FILE.\n\n");
65 printf(" The following OPTIONS are accepted:\n"); 65 printf(" The following OPTIONS are accepted:\n");
66 printf(" -d, --debug enable communication debugging\n"); 66 printf(" -d, --debug enable communication debugging\n");
67 printf(" -u, --udid UDID target specific device by its 40-digit device UDID\n"); 67 printf(" -u, --udid UDID target specific device by UDID\n");
68 printf(" -x, --xml print XML output when using the 'dump' command\n"); 68 printf(" -x, --xml print XML output when using the 'dump' command\n");
69 printf(" -h, --help prints usage information\n"); 69 printf(" -h, --help prints usage information\n");
70 printf("\n"); 70 printf("\n");
@@ -299,7 +299,7 @@ int main(int argc, char *argv[])
299 } 299 }
300 else if (!strcmp(argv[i], "-u") || !strcmp(argv[i], "--udid")) { 300 else if (!strcmp(argv[i], "-u") || !strcmp(argv[i], "--udid")) {
301 i++; 301 i++;
302 if (!argv[i] || (strlen(argv[i]) != 40)) { 302 if (!argv[i] || !*argv[i]) {
303 print_usage(argc, argv); 303 print_usage(argc, argv);
304 return 0; 304 return 0;
305 } 305 }