summaryrefslogtreecommitdiffstats
path: root/src/limera1n.c
diff options
context:
space:
mode:
authorGravatar Aaron Burghardt2013-10-13 15:08:01 -0400
committerGravatar Martin Szulecki2013-10-24 14:41:55 +0200
commit752da7f10c3b19359a84c807a32c9f94154a8aee (patch)
treecc556af619d94468b402ba2427c5eab4b1f5e873 /src/limera1n.c
parent606bd9ce5f4cf34716f7fc8c9202b78e4e353687 (diff)
downloadidevicerestore-752da7f10c3b19359a84c807a32c9f94154a8aee.tar.gz
idevicerestore-752da7f10c3b19359a84c807a32c9f94154a8aee.tar.bz2
Update limera1n_is_supported() for changes to libirecovery project.
Signed-off-by: Martin Szulecki <m.szulecki@libimobiledevice.org>
Diffstat (limited to 'src/limera1n.c')
-rw-r--r--src/limera1n.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/limera1n.c b/src/limera1n.c
index 25d9e40..a716f24 100644
--- a/src/limera1n.c
+++ b/src/limera1n.c
@@ -32,9 +32,17 @@
int limera1n_is_supported(struct irecv_device *device)
{
- return ((device->chip_id == irecv_devices[DEVICE_IPHONE4].chip_id) ||
- (device->chip_id == irecv_devices[DEVICE_IPHONE3GS].chip_id) ||
- (device->chip_id == irecv_devices[DEVICE_IPOD3G].chip_id));
+ irecv_device_t iphone4 = NULL;
+ irecv_device_t iphone3gs = NULL;
+ irecv_device_t ipod3g = NULL;
+
+ irecv_devices_get_device_by_product_type("iPhone3,1", &iphone4);
+ irecv_devices_get_device_by_product_type("iPhone2,1", &iphone3gs);
+ irecv_devices_get_device_by_product_type("iPod3,1", &ipod3g);
+
+ return ((device->chip_id == iphone4->chip_id) ||
+ (device->chip_id == iphone3gs->chip_id) ||
+ (device->chip_id == ipod3g->chip_id));
}
int limera1n_exploit(struct irecv_device *device, irecv_client_t *pclient)