summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2013-09-23 16:03:01 +0200
committerGravatar Martin Szulecki2013-09-23 16:03:01 +0200
commit9d28108baff00cc52570ed820c4cfad0706a54f2 (patch)
treeb0a88d1670cddc2589f6391f0489571b6c974e7f /src
parenta6a00621a0ba122e4959380a8d2926649cc17592 (diff)
downloadidevicerestore-9d28108baff00cc52570ed820c4cfad0706a54f2.tar.gz
idevicerestore-9d28108baff00cc52570ed820c4cfad0706a54f2.tar.bz2
ipsw: Add a temporary workaround to support iOS 7 firmware lookups
It appears that iTunes does no longer parse the version XML structure as currently implemented in idevicerestore. We'll need to modify the lookup for the latest firmware in the future, this will do for a while.
Diffstat (limited to 'src')
-rw-r--r--src/ipsw.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/ipsw.c b/src/ipsw.c
index 8bb5512..2965100 100644
--- a/src/ipsw.c
+++ b/src/ipsw.c
@@ -336,6 +336,11 @@ int ipsw_get_latest_fw(plist_t version_data, const char* product, char** fwurl,
return -1;
}
+ if (major == 11) {
+ /* FIXME workaround as with the iOS 7 release, Apple broke their own XML structure and logic */
+ major = 12;
+ }
+
char majstr[32]; // should be enough for a uint64_t value
sprintf(majstr, FMT_qu, (long long unsigned int)major);
n1 = plist_access_path(version_data, 7, "MobileDeviceSoftwareVersionsByVersion", majstr, "MobileDeviceSoftwareVersions", product, "Unknown", "Universal", "Restore");