summaryrefslogtreecommitdiffstats
path: root/system/xfburn/fix_empty_dir_segfault.diff
diff options
context:
space:
mode:
author Robby Workman <rworkman@slackbuilds.org>2012-09-07 09:18:49 -0500
committer Robby Workman <rworkman@slackbuilds.org>2012-09-07 09:21:30 -0500
commit7ffa46b4a7221ec7c4a28402b362f95abac3e763 (patch)
treedc6471409d8f99aa54c454fb973e3488ea1fec8c /system/xfburn/fix_empty_dir_segfault.diff
parentcf44e6b8d928a9213808d6d6cabc24c63fdefe95 (diff)
downloadslackbuilds-7ffa46b4a7221ec7c4a28402b362f95abac3e763.tar.gz
slackbuilds-7ffa46b4a7221ec7c4a28402b362f95abac3e763.tar.xz
system/xfburn: Included a couple of fixes from Arch Linux
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'system/xfburn/fix_empty_dir_segfault.diff')
-rw-r--r--system/xfburn/fix_empty_dir_segfault.diff47
1 files changed, 47 insertions, 0 deletions
diff --git a/system/xfburn/fix_empty_dir_segfault.diff b/system/xfburn/fix_empty_dir_segfault.diff
new file mode 100644
index 0000000000..b5543a5358
--- /dev/null
+++ b/system/xfburn/fix_empty_dir_segfault.diff
@@ -0,0 +1,47 @@
+--- xfburn/xfburn-data-composition.c 2011-02-17 16:37:03.000000000 +0100
++++ xfburn/xfburn-data-composition_patched.c 2011-02-17 16:40:40.000000000 +0100
+@@ -1874,26 +1874,29 @@
+ g_error ("Failed adding %s as a node to the image: code %X!", src, r);
+ }
+
+- basename = g_path_get_basename (src);
++ /* Check names only for items not manually created (#613563) */
++ if (type != DATA_COMPOSITION_TYPE_DIRECTORY || src != NULL) {
++ basename = g_path_get_basename (src);
++
++ /* check if the file has been renamed */
++ if (strcmp (basename, name) != 0) {
++ /* rename the iso_node */
++ r = iso_node_set_name (node, name);
++
++ if (r == 0) {
++ /* The first string is the renamed name, the second one the original name */
++ xfce_warn (_("Duplicate filename '%s' for '%s'"), name, src);
++
++ g_free (basename);
++ g_free (name);
++ g_free (src);
+
+- /* check if the file has been renamed */
+- if (strcmp (basename, name) != 0) {
+- /* rename the iso_node */
+- r = iso_node_set_name (node, name);
+-
+- if (r == 0) {
+- /* The first string is the renamed name, the second one the original name */
+- xfce_warn (_("Duplicate filename '%s' for '%s'"), name, src);
+-
+- g_free (basename);
+- g_free (name);
+- g_free (src);
+-
+- continue;
++ continue;
++ }
+ }
++ g_free (basename);
+ }
+
+- g_free (basename);
+ g_free (name);
+ g_free (src);