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 756391 - Control center crashes after disabling Sharing
Control center crashes after disabling Sharing
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Sharing
3.18.x
Other Linux
: High critical
: ---
Assigned To: Control-Center Maintainers
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-10-11 15:21 UTC by Dušan
Modified: 2015-10-11 15:51 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
sharing: Fix crash when disabling sharing (1.05 KB, patch)
2015-10-11 15:37 UTC, Bastien Nocera
committed Details | Review

Description Dušan 2015-10-11 15:21:05 UTC
When i have once enabled sharing in control center and THEN i try to disable it with toggle button, window with Sharing view crashes and Sharing stays enabled at all.

Log from terminal:

[dusan@dusan ~]$ gnome-control-center

(gnome-control-center:13863): Gtk-CRITICAL **: gtk_widget_is_visible: assertion 'GTK_IS_WIDGET (widget)' failed

(gnome-control-center:13863): Gtk-CRITICAL **: gtk_widget_is_visible: assertion 'GTK_IS_WIDGET (widget)' failed
**
sharing-cc-panel:ERROR:cc-sharing-panel.c:56:_gtk_builder_get_widget: assertion failed: (w != NULL)
Comment 1 Bastien Nocera 2015-10-11 15:26:09 UTC
I need a backtrace of the crash to be able to do something with it.

Either launch "set environment G_DEBUG fatal_warnings" in gdb when gathering the backtrace, or if you're not familiar with gdb, run:
G_DEBUG=fatal_warnings gnome-control-center
reproduce the crash, and use your distribution's bug reporting system to gather a backtrace.

More information is available at:
https://wiki.gnome.org/Community/GettingInTouch/Bugzilla/GettingTraces
Comment 2 Dušan 2015-10-11 15:36:31 UTC
i get something like this in GDB(if is information incomplete, give me please more advices how to obtain right log):

Starting program: /usr/bin/gnome-control-center 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[New Thread 0x7fffcc58c700 (LWP 15009)]
[New Thread 0x7fffcbd8b700 (LWP 15010)]
[New Thread 0x7fffc9753700 (LWP 15013)]
[New Thread 0x7fffc8f52700 (LWP 15014)]
[Thread 0x7fffc8f52700 (LWP 15014) exited]

(gnome-control-center:15005): Gtk-CRITICAL **: gtk_widget_is_visible: assertion 'GTK_IS_WIDGET (widget)' failed

Program received signal SIGTRAP, Trace/breakpoint trap.
0x00007fffefc6a64b in g_logv () from /usr/lib/libglib-2.0.so.0
Comment 3 Dušan 2015-10-11 15:37:16 UTC
before i get somethins like this:

Starting program: /usr/bin/gnome-control-center 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[New Thread 0x7fffcc58c700 (LWP 14985)]
[New Thread 0x7fffcbd8b700 (LWP 14986)]
[New Thread 0x7fffc9753700 (LWP 14988)]
[New Thread 0x7fffc8f52700 (LWP 14989)]
[Thread 0x7fffc9753700 (LWP 14988) exited]

(gnome-control-center:14981): Gtk-CRITICAL **: gtk_widget_is_visible: assertion 'GTK_IS_WIDGET (widget)' failed

(gnome-control-center:14981): Gtk-CRITICAL **: gtk_widget_is_visible: assertion 'GTK_IS_WIDGET (widget)' failed
**
sharing-cc-panel:ERROR:cc-sharing-panel.c:56:_gtk_builder_get_widget: assertion failed: (w != NULL)

Program received signal SIGABRT, Aborted.
0x00007fffef5ab5f8 in raise () from /usr/lib/libc.so.6
Comment 4 Bastien Nocera 2015-10-11 15:37:27 UTC
Created attachment 313062 [details] [review]
sharing: Fix crash when disabling sharing

Left-over code from 9d45904f3c2e06240574145f9916686475497803 meant that
we'd try to disable a non-existent switch.
Comment 5 Bastien Nocera 2015-10-11 15:39:02 UTC
(In reply to Dušan from comment #2)
> i get something like this in GDB(if is information incomplete, give me
> please more advices how to obtain right log):
> 
> Starting program: /usr/bin/gnome-control-center 
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/usr/lib/libthread_db.so.1".
> [New Thread 0x7fffcc58c700 (LWP 15009)]
> [New Thread 0x7fffcbd8b700 (LWP 15010)]
> [New Thread 0x7fffc9753700 (LWP 15013)]
> [New Thread 0x7fffc8f52700 (LWP 15014)]
> [Thread 0x7fffc8f52700 (LWP 15014) exited]
> 
> (gnome-control-center:15005): Gtk-CRITICAL **: gtk_widget_is_visible:
> assertion 'GTK_IS_WIDGET (widget)' failed
> 
> Program received signal SIGTRAP, Trace/breakpoint trap.
> 0x00007fffefc6a64b in g_logv () from /usr/lib/libglib-2.0.so.0

At that point you usually need to type "bt" to get a backtrace of the crash.

But I've managed to reproduce it, and the above patch fixes it.
Comment 6 Bastien Nocera 2015-10-11 15:41:22 UTC
Attachment 313062 [details] pushed as 9315eb0 - sharing: Fix crash when disabling sharing
Comment 7 Dušan 2015-10-11 15:51:58 UTC
thank you for ultra quick fix. you are great ;-) keep up good work man