mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
831f5fe210
Summary: There exists race condition in `sendRequest:withDelegate:` method, it can do the session creation multiple times, because we don't lock that, which would leads `EXC_BAD_ACCESS` because use and deallocated session concurrently, we can refer to how to create a singleton safely. Related https://github.com/facebook/react-native/issues/25152. ## Changelog [iOS] [Fixed] - Fixes race condition of Network module Pull Request resolved: https://github.com/facebook/react-native/pull/25156 Differential Revision: D15671734 Pulled By: sammy-SC fbshipit-source-id: 5021e6cf33c2b55e3f7adf573ab5c8e6a8d82e23