Fix GFileInfo leak in thunar_job_operation_restore_from_trash
Leak report
Direct leak of 40 byte(s) in 1 object(s) allocated from:
#0 0x63cb8ddedc59 in calloc (/usr/asan/bin/thunar+0x498c59)
#1 0x76408f5d50ca in g_malloc0 glib/gmem.c:133:13
#2 0x76408fdb74ac in g_type_create_instance gobject/gtype.c:1933:17
#3 0x76408fd86a0d in g_object_new_internal gobject/gobject.c:2606:24
#4 0x76408fd8514b in g_object_new_with_properties gobject/gobject.c:2769:14
#5 0x76408fd8514b in g_object_new gobject/gobject.c:2415:12
#6 0x76408dbe05c4 in _g_dbus_get_file_info gvfs/common/gvfsdaemonprotocol.c:335:10
#7 0x76408ddb9621 in handle_got_info gvfs/client/gdaemonfileenumerator.c:233:14
#8 0x76408dbc6f7c in _g_dbus_codegen_marshal_BOOLEAN__OBJECT_VARIANT gvfs/common/gvfsdbus.c:423:5
#9 0x76408fd75d30 in g_closure_invoke gobject/gclosure.c:833:7
#10 0x76408fdb012e in signal_emit_unlocked_R gobject/gsignal.c:3887:8
#11 0x76408fdab808 in signal_emitv_unlocked gobject/gsignal.c:3211:3
#12 0x76408fdab808 in g_signal_emitv gobject/gsignal.c:3111:3
#13 0x76408dbd0a28 in _gvfs_dbus_enumerator_skeleton_handle_method_call gvfs/common/gvfsdbus.c:18421:3
#14 0x76408fbd16f4 in g_dbus_interface_method_dispatch_helper gio/gdbusinterfaceskeleton.c:618:7
#15 0x76408fb9b903 in call_in_idle_cb gio/gdbusconnection.c:5458:3
#16 0x76408f5c1102 in g_main_dispatch glib/gmain.c:3357:27
#17 0x76408f5c1102 in g_main_context_dispatch_unlocked glib/gmain.c:4208:7
#18 0x76408f5c1dcf in g_main_context_iterate_unlocked glib/gmain.c:4273:5
#19 0x76408f5c2637 in g_main_loop_run glib/gmain.c:4475:5
#20 0x76408ddb868b in g_daemon_file_enumerator_next_file gvfs/client/gdaemonfileenumerator.c:531:7
#21 0x76408fa4f4fd in g_file_enumerator_next_file gio/gfileenumerator.c:240:10
#22 0x63cb8dfff58a in thunar_job_operation_restore_from_trash thunar/thunar-job-operation.c:716:15
#23 0x63cb8dffe478 in thunar_job_operation_execute thunar/thunar-job-operation.c:509:9
#24 0x63cb8e00392a in thunar_job_operation_history_undo thunar/thunar-job-operation-history.c:371:26
#25 0x63cb8e2743e8 in thunar_window_action_undo thunar/thunar-window.c:3750:3
[...snip...]
Steps to reproduce
- Delete a file
- Undo to restore the file from trash
Testing
- No issues were detected with LSan, ASan, or Valgrind when testing the patch