After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 475476 - valgrind reports leaks in gnome-panel
valgrind reports leaks in gnome-panel
Status: RESOLVED OBSOLETE
Product: gnome-panel
Classification: Other
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Panel Maintainers
Panel Maintainers
Depends on:
Blocks:
 
 
Reported: 2007-09-10 14:06 UTC by Kjartan Maraas
Modified: 2015-03-24 13:01 UTC
See Also:
GNOME target: ---
GNOME version: 2.19/2.20



Description Kjartan Maraas 2007-09-10 14:06:10 UTC
Here's a few leaks reported by valgrind:

==2821== 32 bytes in 1 blocks are definitely lost in loss record 62 of 225
==2821==    at 0x4022525: malloc (vg_replace_malloc.c:149)
==2821==    by 0x50FB37F: strdup (in /lib/libc-2.6.90.so)
==2821==    by 0x43B57BB: _gnome_vfs_xdg_hash_append_glob (xdgmimeglob.c:480)
==2821==    by 0x43B58FC: _gnome_vfs_xdg_glob_read_from_file (xdgmimeglob.c:543)
==2821==    by 0x43B3E2A: xdg_mime_init_from_directory (xdgmime.c:158)
==2821==    by 0x43B323F: xdg_run_command_on_dirs (xdgmime.c:267)
==2821==    by 0x43B35F0: xdg_mime_init (xdgmime.c:434)
==2821==    by 0x43B3916: _gnome_vfs_xdg_unalias_mime_type (xdgmime.c:643)
==2821==    by 0x439BD49: get_entry (gnome-vfs-mime-info.c:478)
==2821==    by 0x439C344: gnome_vfs_mime_get_value (gnome-vfs-mime-info.c:545)
==2821==    by 0x439AF26: gnome_vfs_mime_get_icon (gnome-vfs-mime-handlers.c:208)
==2821==    by 0x4096E97: gnome_icon_lookup (gnome-icon-lookup.c:108)
==2821==    by 0x40974E5: gnome_icon_lookup_sync (gnome-icon-lookup.c:444)
==2821==    by 0x8074509: panel_util_get_icon_for_uri (panel-util.c:1541)
==2821==    by 0x808E50A: panel_place_menu_item_create_menu (panel-menu-items.c:449)
==2821==    by 0x808ED9D: panel_place_menu_item_new (panel-menu-items.c:915)
==2821==    by 0x808ADAC: panel_menu_bar_init (panel-menu-bar.c:147)
==2821==    by 0x4EC3FC9: g_type_create_instance (gtype.c:1569)
==2821==    by 0x4EAB0D1: g_object_constructor (gobject.c:1046)
==2821==    by 0x4EA931A: g_object_newv (gobject.c:937)
==2821==    by 0x4EA9EBE: g_object_new_valist (gobject.c:986)
==2821==    by 0x4EAA06F: g_object_new (gobject.c:795)
==2821==    by 0x808A483: panel_menu_bar_load_from_gconf (panel-menu-bar.c:320)
==2821==    by 0x807123B: panel_applet_load_idle_handler (applet.c:909)
==2821==    by 0x4EFEFA0: g_idle_dispatch (gmain.c:4132)
==2821==    by 0x4F00B6B: g_main_context_dispatch (gmain.c:2061)
==2821==    by 0x4F03F9E: g_main_context_iterate (gmain.c:2694)
==2821==    by 0x4F04348: g_main_loop_run (gmain.c:2898)
==2821==    by 0x470F0E3: gtk_main (gtkmain.c:1144)
==2821==    by 0x80603F4: main (main.c:95)

==2825== 1,763 bytes in 54 blocks are definitely lost in loss record 187 of 232
==2825==    at 0x4022525: malloc (vg_replace_malloc.c:149)
==2825==    by 0x4F084D5: g_malloc (gmem.c:131)
==2825==    by 0x4F20AC2: g_strjoin (gstrfuncs.c:2549)
==2825==    by 0x4031EE6: ditem_execute (gnome-desktop-item.c:1702)
==2825==    by 0x4032481: gnome_desktop_item_launch_on_screen_with_env (gnome-desktop-item.c:2107)
==2825==    by 0x8076856: panel_ditem_launch (panel-util.c:55)
==2825==    by 0x80768BC: panel_launch_desktop_file (panel-util.c:131)
==2825==    by 0x808D3AE: panel_menu_item_activate_desktop_file (panel-menu-items.c:1069)
==2825==    by 0x4EB12E8: g_cclosure_marshal_VOID__VOID (gmarshal.c:77)
==2825==    by 0x4EA3EB1: g_closure_invoke (gclosure.c:490)
==2825==    by 0x4EB49EC: signal_emit_unlocked_R (gsignal.c:2440)
==2825==    by 0x4EB5EF6: g_signal_emit_valist (gsignal.c:2199)
==2825==    by 0x4EB60B8: g_signal_emit (gsignal.c:2243)
==2825==    by 0x4854D97: gtk_widget_activate (gtkwidget.c:4706)
==2825==    by 0x47256F9: gtk_menu_shell_activate_item (gtkmenushell.c:1145)
==2825==    by 0x472777D: gtk_menu_shell_button_release (gtkmenushell.c:669)
==2825==    by 0x471CBBC: gtk_menu_button_release (gtkmenu.c:2715)
==2825==    by 0x4715971: _gtk_marshal_BOOLEAN__BOXED (gtkmarshalers.c:84)
==2825==    by 0x4EA26A8: g_type_class_meta_marshal (gclosure.c:567)
==2825==    by 0x4EA3EB1: g_closure_invoke (gclosure.c:490)
==2825==    by 0x4EB5032: signal_emit_unlocked_R (gsignal.c:2478)
==2825==    by 0x4EB5CBE: g_signal_emit_valist (gsignal.c:2209)
==2825==    by 0x4EB60B8: g_signal_emit (gsignal.c:2243)
==2825==    by 0x484F387: gtk_widget_event_internal (gtkwidget.c:4675)
==2825==    by 0x470D87D: gtk_propagate_event (gtkmain.c:2317)
==2825==    by 0x470EC51: gtk_main_do_event (gtkmain.c:1537)
==2825==    by 0x4ABB529: gdk_event_dispatch (gdkevents-x11.c:2351)
==2825==    by 0x4F00B6B: g_main_context_dispatch (gmain.c:2061)
==2825==    by 0x4F03F9E: g_main_context_iterate (gmain.c:2694)
==2825==    by 0x4F04348: g_main_loop_run (gmain.c:2898)

==2729== 1,551 (296 direct, 1,255 indirect) bytes in 8 blocks are definitely lost in loss record 124 of 215
==2729==    at 0x4021864: calloc (vg_replace_malloc.c:279)
==2729==    by 0x4F0843D: g_malloc0 (gmem.c:150)
==2729==    by 0x4DAEA82: ORBit_objref_new (corba-object.c:152)
==2729==    by 0x4DAF2BF: ORBit_objref_find (corba-object.c:196)
==2729==    by 0x4DAF4A8: ORBit_demarshal_object (corba-object.c:612)
==2729==    by 0x4DB6257: ORBit_demarshal_value (corba-any.c:533)
==2729==    by 0x4DAC524: orbit_small_demarshal (orbit-small.c:425)
==2729==    by 0x4DAD31B: ORBit_small_invoke_stub (orbit-small.c:663)
==2729==    by 0x4DAD50D: ORBit_small_invoke_stub_n (orbit-small.c:575)
==2729==    by 0x4DB9DC1: ORBit_c_stub_invoke (poa.c:2643)
==2729==    by 0x432A6ED: Bonobo_Control_getPopupContainer (Bonobo-stubs.c:981)
==2729==    by 0x4139FC7: bonobo_control_frame_get_popup_component (bonobo-control-frame.c:1136)
==2729==    by 0x808459B: panel_applet_frame_activated (panel-applet-frame.c:1336)
==2729==    by 0x4313430: get_async2_cb (bonobo-moniker-util.c:939)
==2729==    by 0x431376E: resolve_async_cb (bonobo-moniker-util.c:834)
==2729==    by 0x4DAC0F0: async_recv_cb (orbit-small.c:1153)
==2729==    by 0x4DA57D7: giop_invoke_async (giop.c:601)
==2729==    by 0x4DA91E5: giop_connection_handle_input (giop-recv-buffer.c:1135)
==2729==    by 0x4DC6BDC: link_connection_io_handler (linc-connection.c:1412)
==2729==    by 0x4DC99FD: link_source_dispatch (linc-source.c:159)
==2729==    by 0x4F00B6B: g_main_context_dispatch (gmain.c:2061)
==2729==    by 0x4F03F9E: g_main_context_iterate (gmain.c:2694)
==2729==    by 0x4F04348: g_main_loop_run (gmain.c:2898)
==2729==    by 0x470F0E3: gtk_main (gtkmain.c:1144)
==2729==    by 0x80603F4: main (main.c:95)

==2729== 2,859 (2,103 direct, 756 indirect) bytes in 62 blocks are definitely lost in loss record 178 of 215
==2729==    at 0x4022525: malloc (vg_replace_malloc.c:149)
==2729==    by 0x4F084D5: g_malloc (gmem.c:131)
==2729==    by 0x4F1CD2A: g_slice_alloc (gslice.c:824)
==2729==    by 0x4F1D414: g_slice_alloc0 (gslice.c:833)
==2729==    by 0x4EC3BA6: g_type_create_instance (gtype.c:1549)
==2729==    by 0x4EAB0D1: g_object_constructor (gobject.c:1046)
==2729==    by 0x4316150: bonobo_object_constructor (bonobo-object.c:820)
==2729==    by 0x4EA931A: g_object_newv (gobject.c:937)
==2729==    by 0x4EA9EBE: g_object_new_valist (gobject.c:986)
==2729==    by 0x4EAA06F: g_object_new (gobject.c:795)
==2729==    by 0x430B407: bonobo_moniker_context_new (bonobo-moniker-context.c:71)
==2729==    by 0x430C9C6: bonobo_context_init (bonobo-context.c:91)
==2729==    by 0x4310886: bonobo_init_full (bonobo-main.c:234)
==2729==    by 0x431098B: bonobo_init (bonobo-main.c:256)
==2729==    by 0x41DA409: bonobo_post_args_parse (gnome-init.c:72)
==2729==    by 0x41D4DD9: gnome_program_postinit (gnome-program.c:1825)
==2729==    by 0x41D5214: gnome_program_init_common (gnome-program.c:2062)
==2729==    by 0x41D5540: gnome_program_init (gnome-program.c:1878)
==2729==    by 0x806035B: main (main.c:59)
Comment 1 Vincent Untz 2007-09-10 15:14:40 UTC
Not critical, but adding to the TODO list.
Comment 2 Kjartan Maraas 2007-09-25 06:07:59 UTC
The ditem_execute() leak should be fixed by this:

2007-09-25  Glynn Foster  <glynn.foster@sun.com>

        * gnome-desktop-item.c: (make_environment_for_screen): Use 
        g_strfreev () to free the vector instead of g_free () so we
        don't leak. Help from Dan Mick, the libumem hero.
Comment 3 Martin Mai 2009-02-01 13:15:34 UTC
There was a bug on launchpad about a leak in the gnome-panel run dialog (https://bugs.launchpad.net/ubuntu/+source/gnome-panel/+bug/138006) which seems fixed. I am just wondering if this bug can be closed?
Comment 4 Kjartan Maraas 2011-02-08 18:24:56 UTC
Closing as obsolete now that we don't use gnome-vfs and friends.