Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 21 Aug 2012 14:54:39 GMT
From:      Greg Becker <greg@codeconcepts.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/170825: xfce4-session takes segmentation fault while trying to save session
Message-ID:  <201208211454.q7LEsdrV039462@red.freebsd.org>
Resent-Message-ID: <201208211500.q7LF0O7x013709@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         170825
>Category:       ports
>Synopsis:       xfce4-session takes segmentation fault while trying to save session
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Aug 21 15:00:24 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Greg Becker
>Release:        9.1-PRERELEASE
>Organization:
>Environment:
FreeBSD groover.i.cacheiq.com 9.1-PRERELEASE FreeBSD 9.1-PRERELEASE #2: Sun Aug 19 18:01:49 CDT 2012     greg@snoopy.cc.codeconcepts.com:/usr/obj/usr/src/sys/GROOVER  amd64

>Description:
xfce4 doesn't save sessions.  If you explicitly try to save a session via the "Session" tab in the "Session and Startup" control panel xfce4-session drops core and kills the X session.

Look like manager->session_file is NULL on entry to xfsm_manager_store_session():

$ gdb xfce4-session xfce4-session.core 
Core was generated by `xfce4-session'.
Program terminated with signal 11, Segmentation fault.

#0  0x0000000803cfd5d7 in strlen () from /lib/libc.so.7
[New Thread 808c07400 (LWP 100572/xfce4-session)]
(gdb) backt
#0  0x0000000803cfd5d7 in strlen () from /lib/libc.so.7
#1  0x000000080353c36b in g_string_chunk_insert_len ()
   from /usr/local/lib/libglib-2.0.so.0
#2  0x0000000801085468 in xfce_rc_simple_open ()
   from /usr/local/lib/libxfce4util.so.6
#3  0x0000000801083a6d in xfce_rc_simple_open ()
   from /usr/local/lib/libxfce4util.so.6
#4  0x0000000000419d6e in xfsm_manager_store_session (manager=0x808c4c800)
    at xfsm-manager.c:1609
#5  0x0000000000419b61 in xfsm_manager_complete_saveyourself (
    manager=0x808c4c800) at xfsm-manager.c:1524
#6  0x000000000041954a in xfsm_manager_save_yourself_done (
    manager=0x808c4c800, client=0x808c13630, success=1) at xfsm-manager.c:1280
#7  0x00000000004101fa in sm_save_yourself_done (sms_conn=0x808c41d00, 
    client_data=0x808c13630, success=1) at sm-layer.c:304
#8  0x0000000800c61086 in _SmsProcessMessage () from /usr/local/lib/libSM.so.6
#9  0x0000000800e73c30 in IceProcessMessages () from /usr/local/lib/libICE.so.6
#10 0x000000000040e9e2 in ice_process_messages (channel=0x808cbaa00, 
    condition=G_IO_IN, user_data=0x808e9c6d0) at ice-layer.c:111
#11 0x00000008035198b3 in g_main_context_dispatch ()
   from /usr/local/lib/libglib-2.0.so.0
#12 0x000000080351d8d2 in g_main_context_prepare ()
   from /usr/local/lib/libglib-2.0.so.0
#13 0x000000080351dcc5 in g_main_loop_run ()
   from /usr/local/lib/libglib-2.0.so.0
#14 0x000000080160e303 in gtk_main () from /usr/local/lib/libgtk-x11-2.0.so.0
#15 0x000000000040f8b5 in main (argc=1, argv=0x7fffffffd028) at main.c:308
(gdb) f 4
#4  0x0000000000419d6e in xfsm_manager_store_session (manager=0x808c4c800)
    at xfsm-manager.c:1609
1609	  rc = xfce_rc_simple_open (manager->session_file, FALSE);
(gdb) p manager.session_file
$1 = (gchar *) 0x0

(gdb) set print pretty
(gdb) p *manager
$3 = {
  parent = {
    g_type_instance = {
      g_class = 0x808cbd880
    }, 
    ref_count = 1, 
    qdata = 0x808c42700
  }, 
  state = XFSM_MANAGER_CHECKPOINT, 
  shutdown_type = XFSM_SHUTDOWN_LOGOUT, 
  shutdown_helper = 0x808c0b000, 
  session_chooser = 0, 
  session_name = 0x808c3a4b0 "Default", 
  session_file = 0x0, 
  checkpoint_session_name = 0x0, 
  start_at = 0, 
  compat_gnome = 0, 
  compat_kde = 0, 
  starting_properties = 0x808c42780, 
  pending_properties = 0x808c427a0, 
  restart_properties = 0x808c42760, 
  running_clients = 0x808c42740, 
  failsafe_mode = 1, 
  failsafe_clients = 0x808c42720, 
  die_timeout_id = 0, 
  session_bus = 0x808d1f288
}

I've got the non-stripped xfce4-session binary and core if anyone is interested.

>How-To-Repeat:
Fresh install of FreeBSD 9, updated to latest stable.
Ports updated to latest.

Got to the "Session" tab in the "Session and Startup" control panel and click the "Save Session" button.

>Fix:
You can prevent xfce4-session from dropping core by trapping the NULL session_file pointer and returning, but upon return to the X session from the console the screen is black and the screeen never redraws.


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201208211454.q7LEsdrV039462>