fix crash if we fail to convert a filename to UTF-8
2007-10-09 Jens Granseuer <jensgr@gmx.net> * appearance-desktop.c: (wp_props_wp_set): fix crash if we fail to convert a filename to UTF-8 svn path=/trunk/; revision=8164
This commit is contained in:
parent
a3ed7ad920
commit
5ed22b4a3a
2 changed files with 11 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2007-10-09 Jens Granseuer <jensgr@gmx.net>
|
||||||
|
|
||||||
|
* appearance-desktop.c: (wp_props_wp_set): fix crash if we fail to
|
||||||
|
convert a filename to UTF-8
|
||||||
|
|
||||||
2007-09-28 Jens Granseuer <jensgr@gmx.net>
|
2007-09-28 Jens Granseuer <jensgr@gmx.net>
|
||||||
|
|
||||||
* appearance-themes.c: (theme_store_sort_func): make theme sorting
|
* appearance-themes.c: (theme_store_sort_func): make theme sorting
|
||||||
|
|
|
@ -600,8 +600,12 @@ wp_props_wp_set (AppearanceData *data, GnomeWPItem *item)
|
||||||
else
|
else
|
||||||
uri = g_filename_to_utf8 (item->filename, -1, NULL, NULL, NULL);
|
uri = g_filename_to_utf8 (item->filename, -1, NULL, NULL, NULL);
|
||||||
|
|
||||||
|
if (uri == NULL) {
|
||||||
|
g_warning ("Failed to convert filename to UTF-8: %s\n", item->filename);
|
||||||
|
} else {
|
||||||
gconf_change_set_set_string (cs, WP_FILE_KEY, uri);
|
gconf_change_set_set_string (cs, WP_FILE_KEY, uri);
|
||||||
g_free (uri);
|
g_free (uri);
|
||||||
|
}
|
||||||
|
|
||||||
gconf_change_set_set_string (cs, WP_OPTIONS_KEY, item->options);
|
gconf_change_set_set_string (cs, WP_OPTIONS_KEY, item->options);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue