-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fetcherCompletion is assign #1565
Comments
@ToFind1991 Sorry for the delayed response. Are you seeing a demonstrable issue with this code? My understanding is that the |
To clarify the object being deallocated here isn't self, it's the |
This stackoverflow answer seems to indicate that while |
|
This comment has been minimized.
This comment has been minimized.
It looks like this issue has somehow re-manifested itself. Even with the EDIT: This can be avoided by using |
@property(readonly) GTMSessionFetcherCompletionHandler fetcherCompletion;
This property is using default assign, so fetcherCompletion will may be released to case a wild pointer and
EXC_BAD_ACCESS
crash.In the file
FIRStorageDownloadTask.m
, there is a assignment forfetcherCompletion
:And at the end of this scope, there is a fetch:
Because this fetch is async, when
weakSelf.fetcherCompletion
calls, the temporary scope in which fetcherCompletion is assigned has gone.fetcherCompletion
become a bad memory.The text was updated successfully, but these errors were encountered: