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 121084 - Segmentation fault when trying to edit or set an unset value
Segmentation fault when trying to edit or set an unset value
Status: RESOLVED FIXED
Product: gconf-editor
Classification: Applications
Component: general
unspecified
Other other
: High critical
: ---
Assigned To: Gconf Editor Maintainers
Gconf Editor Maintainers
: 111352 121874 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2003-08-30 23:11 UTC by piccardi
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
a second patch (just a little change) (696 bytes, patch)
2003-10-31 15:25 UTC, Sebastien Bacher
none Details | Review

Description piccardi 2003-08-30 23:41:57 UTC
Package: gconf-editor
Severity: major
Version: 0.4.0
Synopsis: Segmentation fault when trying to edit or set an unset value
Bugzilla-Product: gconf-editor
Bugzilla-Component: general

Description:
Description of Problem:

I try to edit toolbar_style property of galeon UI, that's unset, but it
just segfault.

Steps to reproduce the problem:
1. try tp edit an unset value
2. 
3. 

Actual Results:
Segfault

Expected Results:
Edit the value

How often does this happen?
Every time

Additional Information:
there was this patch to avoid this, please apply (don't know the version, it' on debian bug report system).

00000 +0100
@@ -386,7 +386,8 @@
                                                   "version."));
                gtk_dialog_run (GTK_DIALOG (dialog));
                gtk_widget_destroy (dialog);
-               gconf_value_free (value);
+               if (value != NULL)
+                       gconf_value_free (value);
                g_free (path);
                return;
        }
@@ -394,7 +395,8 @@
        editor = gconf_key_editor_new (GCONF_KEY_EDITOR_EDIT_KEY);

        gconf_key_editor_set_value (GCONF_KEY_EDITOR (editor), value);
-       gconf_value_free (value);
+       if (value != NULL)
+               gconf_value_free (value);

        gconf_key_editor_set_key_name (GCONF_KEY_EDITOR (editor), path);
        g_free (path);




------- Bug moved to this database by unknown@bugzilla.gnome.org 2003-08-30 19:41 -------

The original reporter (piccardi@firenze.linux.it) of this bug does not have an account here.
Reassigning to the exporter, unknown@bugzilla.gnome.org.
Reassigning to the default owner of the component, gconf-editor-maint@bugzilla.gnome.org.

Comment 1 Vincent Untz 2003-09-22 23:14:29 UTC
*** Bug 111352 has been marked as a duplicate of this bug. ***
Comment 2 Vincent Untz 2003-09-22 23:16:15 UTC
*** Bug 121874 has been marked as a duplicate of this bug. ***
Comment 3 Vincent Untz 2003-09-22 23:20:45 UTC
Bug #121874 has a stack trace that confirms the bug. Anyone to review
the patch ?
Comment 4 Vincent Untz 2003-10-21 23:20:24 UTC
Anyone to review the patch?
Comment 5 Josselin Mouette 2003-10-24 20:33:25 UTC
With gconf 2.4.0.1, gconf_value_free tests the pointer for NULLity, so
this patch is probably unuseful now.

Can anyone still reproduce the bug?
Comment 6 Sebastien Bacher 2003-10-31 15:25:13 UTC
Created attachment 21092 [details] [review]
a second patch (just a little change)
Comment 7 Sebastien Bacher 2003-10-31 15:25:41 UTC
gconf_value_free() should not be called with an empty argument. I've
attached a another patch with a simple modification (the patch work
fine and has been tested by 2 people).

I would like to commit it (the fix is pretty easy and the bug opened
for 2 months).
Comment 8 Sebastien Bacher 2003-11-11 14:14:37 UTC
2003-11-11  Sebastien Bacher  <seb128@debian.org>
 
        * src/gconf-editor-window.c: (gconf_editor_new_key_response),
        (gconf_editor_popup_window_edit_key):
        Commited patch to fix the crash with unset values
        (Closes: 121084).