diff options
Diffstat (limited to 'dev/iphone_id.c')
| -rw-r--r-- | dev/iphone_id.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/dev/iphone_id.c b/dev/iphone_id.c index c191608..15081f0 100644 --- a/dev/iphone_id.c +++ b/dev/iphone_id.c | |||
| @@ -3,6 +3,7 @@ | |||
| 3 | #include <stdlib.h> | 3 | #include <stdlib.h> |
| 4 | #include <getopt.h> | 4 | #include <getopt.h> |
| 5 | #include <libiphone/libiphone.h> | 5 | #include <libiphone/libiphone.h> |
| 6 | #include <libiphone/lockdown.h> | ||
| 6 | #include <usbmuxd.h> | 7 | #include <usbmuxd.h> |
| 7 | 8 | ||
| 8 | static void usage() | 9 | static void usage() |
| @@ -18,7 +19,7 @@ static void usage() | |||
| 18 | int main(int argc, char **argv) | 19 | int main(int argc, char **argv) |
| 19 | { | 20 | { |
| 20 | iphone_device_t phone = NULL; | 21 | iphone_device_t phone = NULL; |
| 21 | iphone_lckd_client_t control = NULL; | 22 | lockdownd_client_t client = NULL; |
| 22 | usbmuxd_scan_result *dev_list; | 23 | usbmuxd_scan_result *dev_list; |
| 23 | char *devname = NULL; | 24 | char *devname = NULL; |
| 24 | int ret = 0; | 25 | int ret = 0; |
| @@ -67,18 +68,18 @@ int main(int argc, char **argv) | |||
| 67 | return -2; | 68 | return -2; |
| 68 | } | 69 | } |
| 69 | 70 | ||
| 70 | if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { | 71 | if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) { |
| 71 | iphone_free_device(phone); | 72 | iphone_free_device(phone); |
| 72 | fprintf(stderr, "ERROR: Connecting to device failed!\n"); | 73 | fprintf(stderr, "ERROR: Connecting to device failed!\n"); |
| 73 | return -2; | 74 | return -2; |
| 74 | } | 75 | } |
| 75 | 76 | ||
| 76 | if ((IPHONE_E_SUCCESS != lockdownd_get_device_name(control, &devname)) || !devname) { | 77 | if ((IPHONE_E_SUCCESS != lockdownd_get_device_name(client, &devname)) || !devname) { |
| 77 | fprintf(stderr, "ERROR: Could not get device name!\n"); | 78 | fprintf(stderr, "ERROR: Could not get device name!\n"); |
| 78 | ret = -2; | 79 | ret = -2; |
| 79 | } | 80 | } |
| 80 | 81 | ||
| 81 | iphone_lckd_free_client(control); | 82 | lockdownd_free_client(client); |
| 82 | iphone_free_device(phone); | 83 | iphone_free_device(phone); |
| 83 | 84 | ||
| 84 | if (ret == 0) { | 85 | if (ret == 0) { |
