uncompressedSamples is allocated here:
|
uncompressedSamples = (uint32_t *)malloc(neededunc + 12); |
The free() is supposed to happen during the cleanup:
|
cleanup: |
|
if(uncompressedSamples) |
|
free(uncompressedSamples); |
However, a lot of code paths in this function directly call return instead of assigning ret and jumping to cleanup, which leaks the memory ressources of uncompressedSamples.
Similar to #103, this is likely not a significant problem for short program runs, but it can become a limiting factor for long-running processes.
uncompressedSamplesis allocated here:gpmf-parser/GPMF_parser.c
Line 1388 in 2cc0af7
The
free()is supposed to happen during the cleanup:gpmf-parser/GPMF_parser.c
Lines 1702 to 1704 in 2cc0af7
However, a lot of code paths in this function directly call
returninstead of assigningretand jumping tocleanup, which leaks the memory ressources ofuncompressedSamples.Similar to #103, this is likely not a significant problem for short program runs, but it can become a limiting factor for long-running processes.