diff options
Diffstat (limited to 'dev/filerelaytest.c')
| -rw-r--r-- | dev/filerelaytest.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/dev/filerelaytest.c b/dev/filerelaytest.c index f7e0d07..caaa491 100644 --- a/dev/filerelaytest.c +++ b/dev/filerelaytest.c | |||
| @@ -19,17 +19,17 @@ | |||
| 19 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA | 19 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
| 20 | */ | 20 | */ |
| 21 | #include <stdio.h> | 21 | #include <stdio.h> |
| 22 | #include <libiphone/libiphone.h> | 22 | #include <libimobiledevice/libimobiledevice.h> |
| 23 | #include <libiphone/lockdown.h> | 23 | #include <libimobiledevice/lockdown.h> |
| 24 | #include <libiphone/file_relay.h> | 24 | #include <libimobiledevice/file_relay.h> |
| 25 | 25 | ||
| 26 | int main(int argc, char **argv) | 26 | int main(int argc, char **argv) |
| 27 | { | 27 | { |
| 28 | iphone_device_t dev = NULL; | 28 | idevice_t dev = NULL; |
| 29 | lockdownd_client_t client = NULL; | 29 | lockdownd_client_t client = NULL; |
| 30 | file_relay_client_t frc = NULL; | 30 | file_relay_client_t frc = NULL; |
| 31 | 31 | ||
| 32 | if (iphone_device_new(&dev, NULL) != IPHONE_E_SUCCESS) { | 32 | if (idevice_new(&dev, NULL) != IDEVICE_E_SUCCESS) { |
| 33 | printf("no device connected?!\n"); | 33 | printf("no device connected?!\n"); |
| 34 | goto leave_cleanup; | 34 | goto leave_cleanup; |
| 35 | } | 35 | } |
| @@ -56,7 +56,7 @@ int main(int argc, char **argv) | |||
| 56 | goto leave_cleanup; | 56 | goto leave_cleanup; |
| 57 | } | 57 | } |
| 58 | 58 | ||
| 59 | iphone_connection_t dump = NULL; | 59 | idevice_connection_t dump = NULL; |
| 60 | const char *sources[] = {"AppleSupport", "Network", "VPN", "WiFi", "UserDatabases", "CrashReporter", "tmp", "SystemConfiguration", NULL}; | 60 | const char *sources[] = {"AppleSupport", "Network", "VPN", "WiFi", "UserDatabases", "CrashReporter", "tmp", "SystemConfiguration", NULL}; |
| 61 | 61 | ||
| 62 | printf("Requesting"); | 62 | printf("Requesting"); |
| @@ -83,7 +83,7 @@ int main(int argc, char **argv) | |||
| 83 | FILE *f = fopen("dump.cpio.gz", "w"); | 83 | FILE *f = fopen("dump.cpio.gz", "w"); |
| 84 | setbuf(stdout, NULL); | 84 | setbuf(stdout, NULL); |
| 85 | printf("receiving "); | 85 | printf("receiving "); |
| 86 | while (iphone_connection_receive(dump, buf, 4096, &len) == IPHONE_E_SUCCESS) { | 86 | while (idevice_connection_receive(dump, buf, 4096, &len) == IDEVICE_E_SUCCESS) { |
| 87 | fwrite(buf, 1, len, f); | 87 | fwrite(buf, 1, len, f); |
| 88 | cnt += len; | 88 | cnt += len; |
| 89 | printf(".", len); | 89 | printf(".", len); |
| @@ -101,7 +101,7 @@ leave_cleanup: | |||
| 101 | lockdownd_client_free(client); | 101 | lockdownd_client_free(client); |
| 102 | } | 102 | } |
| 103 | if (dev) { | 103 | if (dev) { |
| 104 | iphone_device_free(dev); | 104 | idevice_free(dev); |
| 105 | } | 105 | } |
| 106 | 106 | ||
| 107 | return 0; | 107 | return 0; |
