summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Fischer <joeljfischer@gmail.com>2018-02-20 14:29:06 -0500
committerGitHub <noreply@github.com>2018-02-20 14:29:06 -0500
commit2d459498513330be423f7b8f523f326aae29cb2b (patch)
treebd4120f1969d58766bf332448a45f818c19c8798
parent198f1615c20aedb4efe312efd80fce170ed88c9a (diff)
parent64226d1c45ad77cc8e71aca9335c6dda35f69921 (diff)
downloadsdl_ios-2d459498513330be423f7b8f523f326aae29cb2b.tar.gz
Merge pull request #870 from t-yoshii/fix/close-ea-session-before-reconnect
Close EA session before reconnect
-rw-r--r--SmartDeviceLink/SDLProxy.m4
1 files changed, 4 insertions, 0 deletions
diff --git a/SmartDeviceLink/SDLProxy.m b/SmartDeviceLink/SDLProxy.m
index 24301c412..7311b7043 100644
--- a/SmartDeviceLink/SDLProxy.m
+++ b/SmartDeviceLink/SDLProxy.m
@@ -100,6 +100,10 @@ static float DefaultConnectionTimeout = 45.0;
if (self.protocol.securityManager != nil) {
[self.protocol.securityManager stop];
}
+
+ if (self.transport != nil) {
+ [self.transport disconnect];
+ }
[[NSNotificationCenter defaultCenter] removeObserver:self];
[[EAAccessoryManager sharedAccessoryManager] unregisterForLocalNotifications];