diff options
author | Martin Szulecki | 2014-05-16 15:03:21 +0200 |
---|---|---|
committer | Martin Szulecki | 2014-05-16 15:03:21 +0200 |
commit | 704afa39c66a6e912f509112f543010b8234ec4d (patch) | |
tree | 0cd4e00d09342da96557323976f512dc17e7dedf /src/restore.c | |
parent | 4533d9e4571da67e1a442581cbc2bef7e4e2338d (diff) | |
download | idevicerestore-704afa39c66a6e912f509112f543010b8234ec4d.tar.gz idevicerestore-704afa39c66a6e912f509112f543010b8234ec4d.tar.bz2 |
restore: Prevent disturbing error message due to missing SEP related components
Diffstat (limited to 'src/restore.c')
-rw-r--r-- | src/restore.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/restore.c b/src/restore.c index f60bec1..7e23bd2 100644 --- a/src/restore.c +++ b/src/restore.c @@ -952,8 +952,8 @@ int restore_send_nor(restored_client_t restore, struct idevicerestore_client_t* unsigned char* personalized_data = NULL; unsigned int personalized_size = 0; - - if (build_identity_get_component_path(build_identity, "RestoreSEP", &restore_sep_path) == 0) { + + if (!build_identity_has_component(build_identity, "RestoreSEP") && build_identity_get_component_path(build_identity, "RestoreSEP", &restore_sep_path) == 0) { component = "RestoreSEP"; if (extract_component(client->ipsw, restore_sep_path, &component_data, &component_size) < 0) { error("ERROR: Unable to extract component: %s\n", component); @@ -961,7 +961,6 @@ int restore_send_nor(restored_client_t restore, struct idevicerestore_client_t* return -1; } - if (personalize_component(component, component_data, component_size, client->tss, &personalized_data, &personalized_size) < 0) { error("ERROR: Unable to get personalized component: %s\n", component); free(component_data); @@ -978,7 +977,7 @@ int restore_send_nor(restored_client_t restore, struct idevicerestore_client_t* personalized_size = 0; } - if (build_identity_get_component_path(build_identity, "SEP", &sep_path) == 0) { + if (!build_identity_has_component(build_identity, "SEP") && build_identity_get_component_path(build_identity, "SEP", &sep_path) == 0) { component = "SEP"; if (extract_component(client->ipsw, sep_path, &component_data, &component_size) < 0) { error("ERROR: Unable to extract component: %s\n", component); @@ -986,7 +985,6 @@ int restore_send_nor(restored_client_t restore, struct idevicerestore_client_t* return -1; } - if (personalize_component(component, component_data, component_size, client->tss, &personalized_data, &personalized_size) < 0) { error("ERROR: Unable to get personalized component: %s\n", component); free(component_data); |