Lines Matching defs:dup
17 char *dup = strdup(pathname);
18 char *ptr = strrchr(stripslash(dup), '/');
19 if (ptr == NULL) return dup;
21 free(dup);
28 char *dup = strdup(pathname);
29 char *ptr = strrchr(stripslash(dup), '/');
30 if (ptr == NULL) { free(dup); return strdup("."); }
31 if (ptr == dup && dup[0] == '/') ptr++;
33 return dup;