How to reproduce:
- Open the attached "IN-143974" project
- Open the "Testing" Scene
- Enter Play mode
- Press the Spacebar key
Actual result: ImageConversion.LoadImage(...) returns false, but Unity leaks a persistent 4096-byte allocation from ALLOC_TEMP_MAIN
Expected result: When ImageConversion.LoadImage(...) fails and returns false, all temporary/native allocations associated with the failed decode should be fully released automatically
Reproducible with 6000.0.0f1, 6000.0.76f1, 6000.3.17f1, 6000.4.10f1, 6000.5.0b11, 6000.6.0a6
Reproducible on: MacOS 26.5 (M1), Windows 11 (reported)
Not reproducible on: No other environments tested
Note: The error message - “TLS Allocator ALLOC_TEMP_TLS, underlying allocator ALLOC_TEMP_MAIN has unfreed allocations, size 204800”