Skip to content

Fix search filter memory leaks

correctmost requested to merge correctmost/xfce4-taskmanager:cm/fix-leaks into master

Description

This commit plugs these leaks:

5 bytes in 1 blocks are definitely lost in loss record 99 of 12,154
   at 0x4843788: malloc (vg_replace_malloc.c:442)
   by 0x5981762: g_malloc (gmem.c:130)
   by 0x599B394: g_strdup (gstrfuncs.c:363)
   by 0x11C24E: g_strdup_inline (gstrfuncs.h:321)
   by 0x11C24E: xtm_process_tree_view_set_filter (process-tree-view.c:683)
   by 0x11306D: filter_entry_keyrelease_handler (process-window.c:197)
   by 0x58D16BF: g_closure_invoke (gclosure.c:832)
   by 0x58FFA35: signal_emit_unlocked_R.isra.0 (gsignal.c:3980)
   by 0x58F0A41: signal_emit_valist_unlocked (gsignal.c:3612)
   by 0x58F0F4F: g_signal_emit_by_name (gsignal.c:3716)
   by 0x4BEDC29: end_change.lto_priv.0 (gtkentry.c:2941)
   by 0x4BF9576: gtk_entry_real_insert_text.lto_priv.0 (gtkentry.c:5401)
   by 0x58D16BF: g_closure_invoke (gclosure.c:832)

10 bytes in 4 blocks are definitely lost in loss record 556 of 12,154
   at 0x4843788: malloc (vg_replace_malloc.c:442)
   by 0x5981762: g_malloc (gmem.c:130)
   by 0x599B47E: g_strndup (gstrfuncs.c:460)
   by 0x113056: filter_entry_keyrelease_handler (process-window.c:196)
   by 0x58D16BF: g_closure_invoke (gclosure.c:832)
   by 0x58FFA35: signal_emit_unlocked_R.isra.0 (gsignal.c:3980)
   by 0x58F0A41: signal_emit_valist_unlocked (gsignal.c:3612)
   by 0x58F0F4F: g_signal_emit_by_name (gsignal.c:3716)
   by 0x4BEDC29: end_change.lto_priv.0 (gtkentry.c:2941)
   by 0x58D16BF: g_closure_invoke (gclosure.c:832)
   by 0x59000E9: signal_emit_unlocked_R.isra.0 (gsignal.c:4020)
   by 0x58F0A41: signal_emit_valist_unlocked (gsignal.c:3612)

Testing

I didn't see any further filter leaks with Valgrind or LeakSanitizer. I also didn't see any memory errors with Valgrind or AddressSanitizer.

Merge request reports

Loading