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 672729 - Crash: gnome-settings-daemon: free(): invalid pointer
Crash: gnome-settings-daemon: free(): invalid pointer
Status: RESOLVED DUPLICATE of bug 670164
Product: libgnomekbd
Classification: Core
Component: Config
3.3.x
Other Linux
: Normal blocker
: ---
Assigned To: libgnomekbd maintainers
Sergey V. Udaltsov
Depends on:
Blocks:
 
 
Reported: 2012-03-23 22:50 UTC by Volker Sobek (weld)
Modified: 2012-03-26 19:56 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
0001-config-fix-segfault-in-gkbd_keyboard_config_options_.patch (1.08 KB, patch)
2012-03-26 12:44 UTC, Olav Vitters
none Details | Review

Description Volker Sobek (weld) 2012-03-23 22:50:47 UTC
version: git commit c11745733ba666cc48cfe2c8de5df4ff6815f673

  • #0 __GI_raise
    at ../nptl/sysdeps/unix/sysv/linux/raise.c line 64
  • #1 __GI_abort
    at abort.c line 91
  • #2 __libc_message
    at ../sysdeps/unix/sysv/linux/libc_fatal.c line 198
  • #3 malloc_printerr
  • #4 _int_free
    at malloc.c line 3948
  • #5 gkbd_keyboard_config_options_equals
    at gkbd-keyboard-config.c line 531
  • #6 gkbd_keyboard_config_equals
    at gkbd-keyboard-config.c line 566
  • #7 try_activating_xkb_config_if_new
    at gsd-keyboard-xkb.c line 323
  • #8 apply_xkb_settings
    at gsd-keyboard-xkb.c line 402
  • #9 apply_xkb_settings
    at gsd-keyboard-xkb.c line 387
  • #10 gsd_keyboard_xkb_init
    at gsd-keyboard-xkb.c line 509
  • #11 start_keyboard_idle_cb
    at gsd-keyboard-manager.c line 280
  • #12 g_main_dispatch
    at gmain.c line 2515
  • #13 g_main_context_dispatch
    at gmain.c line 3052
  • #14 g_main_context_iterate
    at gmain.c line 3123
  • #15 g_main_loop_run
    at gmain.c line 3317
  • #16 gtk_main
    at gtkmain.c line 1161
  • #17 main
    at main.c line 456

Comment 1 Volker Sobek (weld) 2012-03-23 23:39:21 UTC
I undoing commit c9d3c0e939c21230d6088aaf915d9b7d965d97d8 in libgnomekbd seems to 'fix' it.
Comment 2 Volker Sobek (weld) 2012-03-23 23:39:39 UTC
Undoing commit c9d3c0e939c21230d6088aaf915d9b7d965d97d8 in libgnomekbd seems to 'fix' it.
Comment 3 Gert Kulyk 2012-03-25 17:40:34 UTC
I can confirm the crash with libgnomekbd 3.4.0, but not the 'fix'.

You are pointing to a commit that is meant as a fix for bug #670164, but this seems not to be the cause for the crash.

I got it working again reverting commit a6ca20e027edf43df578c7cf1aa26eecb6512540 which is meant as a patch to plug a memleak, but obviously something is wrong there.

By the way: Shouldn't this report be assigned to libgnomekbd rather than to gnome-settings-daemon?
Comment 4 Gert Kulyk 2012-03-25 17:43:29 UTC
Whoops, both patches are part of the fix for bug #670164 ;-)
Comment 5 Volker Sobek (weld) 2012-03-25 21:51:06 UTC
(In reply to comment #4)
> Whoops, both patches are part of the fix for bug #670164 ;-)

Thanks for reference!
Comment 6 Sergey V. Udaltsov 2012-03-25 22:11:05 UTC
The fix is committed. The bad patch is reverted
Comment 7 Olav Vitters 2012-03-26 07:39:26 UTC
FYI: Still getting crash reports @ Mageia with 3.4.0.1. Nothing with stack traces yet.
Comment 8 Sergey V. Udaltsov 2012-03-26 08:25:11 UTC
Olav, Sure it is libgnomekbd?
Comment 9 Olav Vitters 2012-03-26 08:28:50 UTC
Yes, see e.g. https://bugs.mageia.org/show_bug.cgi?id=5098:
  • #4 gkbd_keyboard_config_equals
    from /usr/lib64/libgnomekbd.so.7

I'll get a good stack trace in a bit.
Comment 10 Sergey V. Udaltsov 2012-03-26 10:40:34 UTC
Olav, could you try removing all g_free calls from the second patch of that bug? It should help.
Comment 11 Volker Sobek (weld) 2012-03-26 12:16:03 UTC
3.4.0.1 crashes here too. I accidentally said above 'reverting a6ca20e027edf43df578c7cf1aa26eecb6512540' fixes it, when in fact I meant 'checking out and compiling d63547c01abff6a24920445455c8d2ede2eadd02' fixed it.
Comment 12 Olav Vitters 2012-03-26 12:43:31 UTC
Apparently you did a g_free on a static array?

Another Mageia packager added a patch:

http://svnweb.mageia.org/packages/cauldron/libgnomekbd/current/SOURCES/0001-config-fix-segfault-in-gkbd_keyboard_config_options_.patch?revision=226605&view=markup
Comment 13 Olav Vitters 2012-03-26 12:44:35 UTC
Created attachment 210621 [details] [review]
0001-config-fix-segfault-in-gkbd_keyboard_config_options_.patch

not mine, patch is git formatted, has author
Comment 14 Sergey V. Udaltsov 2012-03-26 19:27:36 UTC
Could you please do a final check that git version is ok now?

*** This bug has been marked as a duplicate of bug 670164 ***
Comment 15 Volker Sobek (weld) 2012-03-26 19:53:39 UTC
=(In reply to comment #14)
> Could you please do a final check that git version is ok now?

ffaf5489fad6588b50384e944c56284e9edef222 works for me.
Comment 16 Olav Vitters 2012-03-26 19:55:54 UTC
Patch in git master matches exactly with the one in Mageia. Had multiple confirmations in Mageia that they can now login again.
Comment 17 Sergey V. Udaltsov 2012-03-26 19:56:42 UTC
Thanks!