diff options
Diffstat (limited to 'tools/idevicename.c')
-rw-r--r-- | tools/idevicename.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/tools/idevicename.c b/tools/idevicename.c index a87872b..97bf2d4 100644 --- a/tools/idevicename.c +++ b/tools/idevicename.c @@ -66,7 +66,7 @@ int main(int argc, char** argv) { NULL, 0, NULL, 0} }; int res = -1; - char* udid = NULL; + const char* udid = NULL; int use_network = 0; #ifndef WIN32 @@ -81,8 +81,7 @@ int main(int argc, char** argv) print_usage(); exit(2); } - free(udid); - udid = strdup(optarg); + udid = optarg; break; case 'n': use_network = 1; @@ -153,9 +152,5 @@ int main(int argc, char** argv) lockdownd_client_free(lockdown); idevice_free(device); - if (udid) { - free(udid); - } - return res; } |