diff options
author | 2025-06-07 12:09:24 +0200 | |
---|---|---|
committer | 2025-06-07 12:09:24 +0200 | |
commit | e3f2d6070de7125058c343ef63961c27bc991bb6 (patch) | |
tree | 2436f76213b34ba2e06db96a990a6f0e17106e6e /src/lockdown.c | |
parent | 2e1ee28bf1d744edcf3513859a38ac5f6615b096 (diff) | |
download | libimobiledevice-e3f2d6070de7125058c343ef63961c27bc991bb6.tar.gz libimobiledevice-e3f2d6070de7125058c343ef63961c27bc991bb6.tar.bz2 |
Add new idevice_get_device_version() to interface
This allows getting a numerical representation of the device's
ProductVersion string for easier version range checks
Diffstat (limited to 'src/lockdown.c')
-rw-r--r-- | src/lockdown.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lockdown.c b/src/lockdown.c index 411136c..a1ad67b 100644 --- a/src/lockdown.c +++ b/src/lockdown.c @@ -659,7 +659,7 @@ lockdownd_error_t lockdownd_client_new(idevice_t device, lockdownd_client_t *cli char *s_version = NULL; plist_get_string_val(p_version, &s_version); if (s_version && sscanf(s_version, "%d.%d.%d", &vers[0], &vers[1], &vers[2]) >= 2) { - device->version = DEVICE_VERSION(vers[0], vers[1], vers[2]); + device->version = IDEVICE_DEVICE_VERSION(vers[0], vers[1], vers[2]); } free(s_version); } @@ -733,7 +733,7 @@ lockdownd_error_t lockdownd_client_new_with_handshake(idevice_t device, lockdown plist_free(pair_record); pair_record = NULL; - if (device->version < DEVICE_VERSION(7,0,0) && device->device_class != DEVICE_CLASS_WATCH) { + if (device->version < IDEVICE_DEVICE_VERSION(7,0,0) && device->device_class != DEVICE_CLASS_WATCH) { /* for older devices, we need to validate pairing to receive trusted host status */ ret = lockdownd_validate_pair(client_loc, NULL); |