summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2014-01-24 16:59:12 +0100
committerStefano Karapetsas <[email protected]>2014-01-24 16:59:12 +0100
commitf586ff0e6382d3a509c587a28f302690519e2339 (patch)
tree211e390ac171723afe402d8d2bbc59d89603bedf
parent3c6456906eb151ce04c02a3b823dbb38830cd977 (diff)
downloadmate-control-center-f586ff0e6382d3a509c587a28f302690519e2339.tar.bz2
mate-control-center-f586ff0e6382d3a509c587a28f302690519e2339.tar.xz
keyboard: Fix segfault
Var may be set as constant value but freed later.
-rw-r--r--capplets/keyboard/mate-keyboard-properties-xkb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/capplets/keyboard/mate-keyboard-properties-xkb.c b/capplets/keyboard/mate-keyboard-properties-xkb.c
index c77459e8..4f795719 100644
--- a/capplets/keyboard/mate-keyboard-properties-xkb.c
+++ b/capplets/keyboard/mate-keyboard-properties-xkb.c
@@ -70,7 +70,7 @@ set_model_text (GtkWidget * picker, gchar * value)
if (model == NULL) {
model = g_strdup(initial_config.model);
if (model == NULL)
- model = "";
+ model = g_strdup("");
}
g_snprintf (ci->name, sizeof (ci->name), "%s", model);