summaryrefslogtreecommitdiffstats
path: root/src/lockdown.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lockdown.c')
-rw-r--r--src/lockdown.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/lockdown.c b/src/lockdown.c
index 70db834..1786536 100644
--- a/src/lockdown.c
+++ b/src/lockdown.c
@@ -152,7 +152,7 @@ static lockdownd_error_t lockdownd_error(property_list_service_error_t err)
152 * LOCKDOWN_E_UNKNOWN_ERROR when the result is 'Failure', 152 * LOCKDOWN_E_UNKNOWN_ERROR when the result is 'Failure',
153 * or a specific error code if derieved from the result. 153 * or a specific error code if derieved from the result.
154 */ 154 */
155static lockdownd_error_t lockdown_check_result(plist_t dict, const char *query_match) 155lockdownd_error_t lockdown_check_result(plist_t dict, const char *query_match)
156{ 156{
157 lockdownd_error_t ret = LOCKDOWN_E_UNKNOWN_ERROR; 157 lockdownd_error_t ret = LOCKDOWN_E_UNKNOWN_ERROR;
158 158
@@ -314,6 +314,10 @@ static lockdownd_error_t lockdownd_client_free_simple(lockdownd_client_t client)
314 if (client->label) { 314 if (client->label) {
315 free(client->label); 315 free(client->label);
316 } 316 }
317 if (client->cu_key) {
318 free(client->cu_key);
319 client->cu_key = NULL;
320 }
317 321
318 free(client); 322 free(client);
319 client = NULL; 323 client = NULL;
@@ -641,8 +645,12 @@ LIBIMOBILEDEVICE_API lockdownd_error_t lockdownd_client_new(idevice_t device, lo
641 client_loc->ssl_enabled = 0; 645 client_loc->ssl_enabled = 0;
642 client_loc->session_id = NULL; 646 client_loc->session_id = NULL;
643 client_loc->device = device; 647 client_loc->device = device;
648 client_loc->cu_key = NULL;
649 client_loc->cu_key_len = 0;
644 650
645 debug_info("device udid: %s", device->udid); 651 if (device->udid) {
652 debug_info("device udid: %s", device->udid);
653 }
646 654
647 client_loc->label = label ? strdup(label) : NULL; 655 client_loc->label = label ? strdup(label) : NULL;
648 656