mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Summary: I discovered this while working on my shim of `UIGraphicsImageRenderer` for macOS (See https://github.com/microsoft/react-native-macos/pull/2209). A variable of type`CGColorRef` is not automatically retained and released when passed into a block. There was a case in `RCTBorderDrawing` where we were doing so. To fix this, we have two options: 1. Pass a `UIColor` instead (Requires a change to the signature of the function calling it) 2. Properly retain and release the variable. The first option would technically be a breaking change (we would need to change the signature of `RCTGetBorderImage`, so I'm opting for option 2. ## Changelog: [IOS] [FIXED] - Properly retain/release backgroundColor in RCTBorderDrawing Pull Request resolved: https://github.com/facebook/react-native/pull/46797 Test Plan: CI should pass. Locally, borders still draw fine for me. Reviewed By: joevilches Differential Revision: D63827824 Pulled By: cipolleschi fbshipit-source-id: 926601d062b90a7d741d7a1af3070cec4b8795ae