src/filesystem.c

changeset 290
2eb3813562e7
parent 86
943bf9d7c6d6
equal deleted inserted replaced
289:237cb9038109 290:2eb3813562e7
44 return cx_strdup(path); 44 return cx_strdup(path);
45 } 45 }
46 46
47 if (base.ptr[base.length - 1] == '/') base.length--; 47 if (base.ptr[base.length - 1] == '/') base.length--;
48 48
49 if (cx_strprefix(path, CX_STR("./"))) { 49 if (cx_strprefix(path, "./")) {
50 path = cx_strsubs(path, 2); 50 path = cx_strsubs(path, 2);
51 } 51 }
52 52
53 return cx_strcat(3, base, CX_STR("/"), path); 53 return cx_strcat(CX_NULLSTR, 3, base, cx_str("/"), path);
54 } 54 }

mercurial