! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
xfce4-settings-helper dumps core without active session manager
Status:
RESOLVED: FIXED
Product:
Libxfcegui4
Component:
General

Comments

Description Eygene Ryabinkin 2009-04-28 21:08:57 CEST
Created attachment 2332 
libxfcegui4: fix two SEGVs

When there is not xfce4-session-manager process an attempt to start xfce4-settings-helper by hand creates the warning message,
-----
(xfce4-settings-helper:86452): xfce4-settings-helper-WARNING **:
Failed to connect to session manager
-----
and then settings-helper dumps core due to the segmentation violation.

There are at least two places in libxfcegui4 that will provoke SEGV:
 1. call to SmcCloseConnection when no connection was established;
 2. an attempt to g_strfreev() of clone_command that contains pointers to a static strings.

The attached patch fixes these issues and it allows me to start settings-helper without active session manager.
Comment 1 Brian J. Tarricone (not reading bugmail) 2009-04-28 22:32:43 CEST
Yeah, patch looks good.  Someone should check this in if I don't get to it sooner.
Comment 2 Eygene Ryabinkin 2009-10-24 18:22:29 CEST
Any progress with this issue?  The patch still applicable and still fixes my problems.
Comment 3 Brian J. Tarricone (not reading bugmail) 2009-10-24 18:28:29 CEST
Your patch probably doesn't apply anymore due to a patch from an older bug that just went in a week ago.  The strdupv things should be fixed, not sure about the other crash.  You should probably take a look at the head of the xfce-4.6 branch and see what needs to be done, if anything.
Comment 4 Eygene Ryabinkin 2009-10-24 18:41:09 CEST
The first hunk is still applicable, because session_client->session_connection can still be zero inside the disconnect() helper.  Second hunk isn't needed anymore.
Comment 5 Brian J. Tarricone (not reading bugmail) 2009-10-24 19:02:51 CEST
Ok... can you attach a new patch?
Comment 6 Eygene Ryabinkin 2009-10-24 19:27:19 CEST
Created attachment 2631 
libxfcegui4: fix SEGV inside disconnect() helper

This is the remainder that is needed after the recent rework of session-client.c [1].

[1] http://git.xfce.org/xfce/libxfcegui4/commit/?h=xfce-4.6&id=caffa2a1e66f44d63ea201f186d5fd0c5337f4bf
Comment 7 Eygene Ryabinkin 2009-10-24 19:29:25 CEST
Created attachment 2632 
libxfcegui4: fix SEGV inside disconnect() helper

Whoops, sorry, attached old improper patch with typo.
Comment 8 Brian J. Tarricone (not reading bugmail) 2009-10-24 20:11:30 CEST
Checked in and pushed, thanks.
Comment 9 Brian J. Tarricone (not reading bugmail) 2009-11-01 23:46:31 CET
*** Bug 5941 has been marked as a duplicate of this bug. ***

Bug #5310

Reported by:
Eygene Ryabinkin
Reported on: 2009-04-28
Last modified on: 2009-11-01
Duplicates (1):
  • 5941 xfce4-settings-helper 4.6.3 crashes

People

Assignee:
Xfce Bug Triage
CC List:
2 users

Version

Version:
unspecified

Attachments

Additional information