application/window.c

changeset 57
d5a7dbc945ef
parent 56
294d5515583a
child 59
6bd37fe6d905
--- a/application/window.c	Wed Oct 23 17:40:45 2024 +0200
+++ b/application/window.c	Wed Oct 23 18:25:28 2024 +0200
@@ -293,7 +293,7 @@
 
 
     cxmutstr base = cx_strdup(cx_strn(full_path, end));
-    cxmutstr base_path = cx_strdup(cx_strcast(base));
+    cxmutstr base_path = cx_strcat(2, cx_strcast(base), CX_STR("/"));
     cxstring path = cx_strsubs(fpath, end + skip);
 
     cxstring *pathelms;
@@ -331,7 +331,7 @@
         elms[j].name_len = m.length;
 
         size_t elm_path_len = c.ptr + c.length - full_path;
-        cxmutstr elm_path = cx_strdup(cx_strn(full_path, elm_path_len));
+        cxmutstr elm_path = cx_strcat(2, cx_strn(full_path, elm_path_len), CX_STR("/"));
         elms[j].path = elm_path.ptr;
         elms[j].path_len = elm_path.length;
 

mercurial