summaryrefslogtreecommitdiff
blob: ab2badb294d9461aa6e995c4e5c200fd3ec458ec (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
http://bugs.gentoo.org/331135
http://bugzilla.xfce.org/show_bug.cgi?id=6805

--- xfburn/xfburn-data-composition.c
+++ xfburn/xfburn-data-composition.c
@@ -1852,26 +1852,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_dialog_show_warning(NULL, NULL, _("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_dialog_show_warning(NULL, NULL, _("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);