summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2013-09-19 20:06:31 +0200
committerGravatar Martin Szulecki2013-09-19 20:06:31 +0200
commit96ef86cc9b61250e2d8a31ba85155a29db6023da (patch)
tree815dce4b2ac94a00b5cedbd1b31b65ecde76ebe3 /src
parentcab6533e63e390dccda15391cf3988e4d706a958 (diff)
downloadlibimobiledevice-96ef86cc9b61250e2d8a31ba85155a29db6023da.tar.gz
libimobiledevice-96ef86cc9b61250e2d8a31ba85155a29db6023da.tar.bz2
lockdown: Don't shutdown SSL during StopSession already or device complains
Diffstat (limited to 'src')
-rw-r--r--src/lockdown.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/lockdown.c b/src/lockdown.c
index 26af6a6..a6f0318 100644
--- a/src/lockdown.c
+++ b/src/lockdown.c
@@ -208,11 +208,15 @@ lockdownd_error_t lockdownd_stop_session(lockdownd_client_t client, const char *
debug_info("success");
ret = LOCKDOWN_E_SUCCESS;
}
+
plist_free(dict);
dict = NULL;
- if (client->ssl_enabled) {
- property_list_service_disable_ssl(client->parent);
+
+ if (client->session_id) {
+ free(client->session_id);
+ client->session_id = NULL;
}
+
return ret;
}
@@ -223,10 +227,6 @@ static lockdownd_error_t lockdownd_client_free_simple(lockdownd_client_t client)
lockdownd_error_t ret = LOCKDOWN_E_UNKNOWN_ERROR;
- if (client->session_id) {
- free(client->session_id);
- }
-
if (client->parent) {
if (property_list_service_client_free(client->parent) == PROPERTY_LIST_SERVICE_E_SUCCESS) {
ret = LOCKDOWN_E_SUCCESS;
@@ -260,7 +260,6 @@ lockdownd_error_t lockdownd_client_free(lockdownd_client_t client)
lockdownd_error_t ret = LOCKDOWN_E_UNKNOWN_ERROR;
-
if (client->session_id) {
lockdownd_stop_session(client, client->session_id);
}