> This is the fix for "JDK-8389515: Memory leak in dshowwrapper - decoded > buffers delivered by CSink are never unmapped" > > The fix adds a second field `m_pMappedGstBuffer` that tracks mapping > ownership independently of the `m_pGstBuffer` delivery ownership that `CSink` > steals, so the unmap always targets the buffer that was actually mapped, and > it is done exactly once. The fix conforms to the buffer life cycle -- > `CAllocator::GetBuffer()` - `CAllocator::ReleaseBuffer()`. > > The reproducer log with the fix applied: > > + d:/work/jdk/jdk25/bin/java.exe @jfx/build/run.args > MemoryLeakReproducer.java demo.mp4 > Java: 25 (OpenJDK 64-Bit Server VM) > JavaFX: 28-internal (runtime 28-internal+0-2026-07-31-112708) > 1015.8 MiB > 1035.6 MiB > 1131.3 MiB > 1132.9 MiB > 1137.8 MiB > 1273.0 MiB > > > --------- > - [x] I confirm that I make this contribution in accordance with the [OpenJDK > Interim AI Policy](https://openjdk.org/legal/ai).
Roman Marchenko has updated the pull request incrementally with one additional commit since the last revision: fix review comments ------------- Changes: - all: https://git.openjdk.org/jfx/pull/2234/files - new: https://git.openjdk.org/jfx/pull/2234/files/619ef6a4..11f1eaaf Webrevs: - full: https://webrevs.openjdk.org/?repo=jfx&pr=2234&range=01 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=2234&range=00-01 Stats: 54 lines in 3 files changed: 37 ins; 12 del; 5 mod Patch: https://git.openjdk.org/jfx/pull/2234.diff Fetch: git fetch https://git.openjdk.org/jfx.git pull/2234/head:pull/2234 PR: https://git.openjdk.org/jfx/pull/2234
