Skip to content

Commit

Permalink
Fixed crash happenned on deallocating RCTSurface
Browse files Browse the repository at this point in the history
Summary:
Essentially, we had `dispatch_async` inside `delloc` method which tried to retain `self`, which is disallowed operation in ObjC runtime.
However, we don't need to notify anything `surface`-related in `_stop` because it always is called from `dealloc`.

Reviewed By: mmmulani

Differential Revision: D6665631

fbshipit-source-id: ed0d192946f3323f4f54ecb99b30e56e0942f174
  • Loading branch information
shergin authored and facebook-github-bot committed Jan 8, 2018
1 parent e46ea8c commit c3139d7
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions React/Base/Surface/RCTSurface.mm
Original file line number Diff line number Diff line change
Expand Up @@ -306,8 +306,6 @@ - (void)_stop
method:@"unmountApplicationComponentAtRootTag"
args:@[self->_rootViewTag]
completion:NULL];

[self _setStage:RCTSurfaceStageSurfaceDidStop];
}

- (void)_registerRootView
Expand Down

0 comments on commit c3139d7

Please sign in to comment.