summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ifuse.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/ifuse.c b/src/ifuse.c
index 3364d35..0aac298 100644
--- a/src/ifuse.c
+++ b/src/ifuse.c
@@ -239,7 +239,10 @@ void *ifuse_init_with_service(struct fuse_conn_info *conn, const char *service_n
return NULL;
}
- iphone_afc_new_client(phone, 3432, port, &afc);
+ iphone_afc_new_client(phone, port, &afc);
+
+ iphone_lckd_free_client(control);
+ control = NULL;
return afc;
}
@@ -249,7 +252,9 @@ void ifuse_cleanup(void *data)
iphone_afc_client_t afc = (iphone_afc_client_t) data;
iphone_afc_free_client(afc);
- iphone_lckd_free_client(control);
+ if (control) {
+ iphone_lckd_free_client(control);
+ }
iphone_free_device(phone);
}