Skip to content

Commit

Permalink
Fix a bug where the SDLRPCResponseDispatcher could crash when being c…
Browse files Browse the repository at this point in the history
…leared
  • Loading branch information
joeljfischer committed Jul 28, 2017
1 parent d5774c1 commit 54b77fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SmartDeviceLink/SDLResponseDispatcher.m
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ - (void)storeRequest:(SDLRPCRequest *)request handler:(nullable SDLResponseHandl

- (void)clear {
// When we get disconnected we have to delete all existing responseHandlers as they are not valid anymore
for (SDLRPCCorrelationId *correlationID in self.rpcResponseHandlerMap) {
for (SDLRPCCorrelationId *correlationID in self.rpcResponseHandlerMap.dictionaryRepresentation) {
SDLResponseHandler responseHandler = self.rpcResponseHandlerMap[correlationID];
responseHandler(self.rpcRequestDictionary[correlationID], nil, [NSError sdl_lifecycle_notConnectedError]);
}
Expand Down

0 comments on commit 54b77fd

Please sign in to comment.