diff options
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/idevicebackup.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/tools/idevicebackup.c b/tools/idevicebackup.c index cacacc4..b3b073a 100644 --- a/tools/idevicebackup.c +++ b/tools/idevicebackup.c | |||
| @@ -594,15 +594,15 @@ int main(int argc, char *argv[]) | |||
| 594 | } | 594 | } |
| 595 | } | 595 | } |
| 596 | 596 | ||
| 597 | /* Manifest.plist (backup manifest (backup state)) */ | ||
| 598 | char *manifest_path = mobilebackup_build_path(backup_directory, "Manifest", ".plist"); | ||
| 599 | |||
| 597 | switch(cmd) { | 600 | switch(cmd) { |
| 598 | case CMD_BACKUP: | 601 | case CMD_BACKUP: |
| 599 | printf("Starting backup...\n"); | 602 | printf("Starting backup...\n"); |
| 600 | /* TODO: check domain com.apple.mobile.backup key RequiresEncrypt and WillEncrypt with lockdown */ | 603 | /* TODO: check domain com.apple.mobile.backup key RequiresEncrypt and WillEncrypt with lockdown */ |
| 601 | /* TODO: verify battery on AC enough battery remaining */ | 604 | /* TODO: verify battery on AC enough battery remaining */ |
| 602 | 605 | ||
| 603 | /* Manifest.plist (backup manifest (backup state)) */ | ||
| 604 | char *manifest_path = mobilebackup_build_path(backup_directory, "Manifest", ".plist"); | ||
| 605 | |||
| 606 | /* read the last Manifest.plist */ | 606 | /* read the last Manifest.plist */ |
| 607 | if (!is_full_backup) { | 607 | if (!is_full_backup) { |
| 608 | printf("Reading existing Manifest.\n"); | 608 | printf("Reading existing Manifest.\n"); |
| @@ -866,10 +866,6 @@ int main(int argc, char *argv[]) | |||
| 866 | } else { | 866 | } else { |
| 867 | printf("Backup Failed.\n"); | 867 | printf("Backup Failed.\n"); |
| 868 | } | 868 | } |
| 869 | |||
| 870 | if (manifest_path) | ||
| 871 | g_free(manifest_path); | ||
| 872 | |||
| 873 | break; | 869 | break; |
| 874 | case CMD_RESTORE: | 870 | case CMD_RESTORE: |
| 875 | /* TODO: verify battery on AC enough battery remaining */ | 871 | /* TODO: verify battery on AC enough battery remaining */ |
| @@ -902,6 +898,8 @@ int main(int argc, char *argv[]) | |||
| 902 | lockfile = 0; | 898 | lockfile = 0; |
| 903 | do_post_notification(NP_SYNC_DID_FINISH); | 899 | do_post_notification(NP_SYNC_DID_FINISH); |
| 904 | } | 900 | } |
| 901 | if (manifest_path) | ||
| 902 | g_free(manifest_path); | ||
| 905 | } else { | 903 | } else { |
| 906 | printf("ERROR: Could not start service %s.\n", MOBILEBACKUP_SERVICE_NAME); | 904 | printf("ERROR: Could not start service %s.\n", MOBILEBACKUP_SERVICE_NAME); |
| 907 | lockdownd_client_free(client); | 905 | lockdownd_client_free(client); |
