core-foundation-rs icon indicating copy to clipboard operation
core-foundation-rs copied to clipboard

Retain calayer after creation

Open xiaopengli89 opened this issue 2 years ago • 4 comments
trafficstars

Run create_calayer test:

signal: 11, SIGSEGV: invalid memory reference

xiaopengli89 avatar Apr 21 '23 05:04 xiaopengli89

:umbrella: The latest upstream changes (presumably b009c87f2da0038bb474800cd88597843e5dbdae) made this pull request unmergeable. Please resolve the merge conflicts.

bors-servo avatar Jul 25 '23 02:07 bors-servo

@xiaopengli89 What is create_calayer test? I'd like to understand the code that is triggering this crash, since I worry that we might end up leaking layer objects with this change.

jdm avatar Sep 10 '23 18:09 jdm

@xiaopengli89 What is create_calayer test? I'd like to understand the code that is triggering this crash, since I worry that we might end up leaking layer objects with this change.

Creating CALayer in autoreleasepool, event loop or child thread will trigger this crash, in which case the runtime will hold ownership of the CALayer.

xiaopengli89 avatar Sep 18 '23 04:09 xiaopengli89

This is also reported in #643

nicoburns avatar May 01 '24 02:05 nicoburns