GNOME Bugzilla – Bug 758161
qtdemux: Fix string memory leak
Last modified: 2015-11-16 08:24:01 UTC
The string got using g_strdup_printf will be allocated memory and should be freed after use. Fixes the below memory leak ==2692== 24 bytes in 1 blocks are definitely lost in loss record 8,801 of 18,861 ==2692== at 0x402C17C: malloc (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==2692== by 0x4B9F2AF: __vasprintf_chk (vasprintf_chk.c:80) ==2692== by 0x4A07689: g_vasprintf (in /lib/i386-linux-gnu/libglib-2.0.so.0.4002.0) ==2692== by 0x49E0FF2: g_strdup_vprintf (in /lib/i386-linux-gnu/libglib-2.0.so.0.4002.0) ==2692== by 0x49E1022: g_strdup_printf (in /lib/i386-linux-gnu/libglib-2.0.so.0.4002.0) ==2692== by 0xF4CE647: qtdemux_parse_tree (qtdemux.c:12763) ==2692== by 0xF4D76B8: gst_qtdemux_loop_state_header (qtdemux.c:3866) ==2692== by 0xF4DBAB0: gst_qtdemux_loop (qtdemux.c:5268) ==2692== by 0x414DBD8: gst_task_func (gsttask.c:331) ==2692== by 0x414ED7E: default_func (gsttaskpool.c:68) ==2692== by 0x49EA404: ??? (in /lib/i386-linux-gnu/libglib-2.0.so.0.4002.0) ==2692== by 0x49E99A9: ??? (in /lib/i386-linux-gnu/libglib-2.0.so.0.4002.0)
Created attachment 315650 [details] [review] fix string leak Fix leak mentioned in above comment and 2 more similar leaks
commit 0d4e3847f0c9106ed345f0316e4954f82332e250 Author: Vineeth TM <vineeth.tm@samsung.com> Date: Mon Nov 16 16:56:04 2015 +0900 qtdemux: Fix string memory leak The string got using g_strdup_printf will be allocated memory and should be freed after use. https://bugzilla.gnome.org/show_bug.cgi?id=758161