Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Manually copy the completion block to the property.

Blocks are not automatically copied by ARC, and that made the demo app crash in release mode after dismissing the WebView. Manually copying the completion block fixes this. Thanks Anton Petrov for finding (and fixing) this bug!

Ref: http://stackoverflow.com/questions/8089896/block-gets-released-whilst-in-nsdictionary-arc
  • Loading branch information...
commit a95d355dbf6c127ff1062be56cece53c53532349 1 parent 73ab8e9
@rsieiro rsieiro authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  TwitterDemo/Twitter/RSTwitterEngine.m
View
2  TwitterDemo/Twitter/RSTwitterEngine.m
@@ -169,7 +169,7 @@ - (void)retrieveOAuthTokenFromKeychain
- (void)authenticateWithCompletionBlock:(RSTwitterEngineCompletionBlock)completionBlock
{
// Store the Completion Block to call after Authenticated
- _oAuthCompletionBlock = completionBlock;
+ _oAuthCompletionBlock = [completionBlock copy];
// First we reset the OAuth token, so we won't send previous tokens in the request
[self resetOAuthToken];
Please sign in to comment.
Something went wrong with that request. Please try again.