summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Nikias Bassen2019-02-12 21:46:48 +0100
committerGravatar Nikias Bassen2019-02-12 21:46:48 +0100
commitcccc965ff1a87ac70d9fe4b10f8cad28c3de2874 (patch)
tree3de002321eec1aa07c066a755ba5d10ef815d4fc /src
parent797a9e7e79d86427f40dbb82d271125b8c0b2485 (diff)
downloadlibimobiledevice-cccc965ff1a87ac70d9fe4b10f8cad28c3de2874.tar.gz
libimobiledevice-cccc965ff1a87ac70d9fe4b10f8cad28c3de2874.tar.bz2
lockdown: Make sure to return correct error code when pairing fails
Diffstat (limited to 'src')
-rw-r--r--src/lockdown.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lockdown.c b/src/lockdown.c
index 2492897..1a162ed 100644
--- a/src/lockdown.c
+++ b/src/lockdown.c
@@ -726,7 +726,7 @@ LIBIMOBILEDEVICE_API lockdownd_error_t lockdownd_client_new_with_handshake(idevi
if (pair_record) {
pair_record_get_host_id(pair_record, &host_id);
}
- if (LOCKDOWN_E_SUCCESS == ret && !host_id) {
+ if (LOCKDOWN_E_SUCCESS == ret && pair_record && !host_id) {
ret = LOCKDOWN_E_INVALID_CONF;
}