Lines Matching defs:path
34 dirname_r(const char* path, char* buffer, size_t bufflen)
40 if (path == NULL || *path == '\0') {
41 path = ".";
47 endp = path + strlen(path) - 1;
48 while (endp > path && *endp == '/')
52 while (endp > path && *endp != '/')
56 if (endp == path) {
57 path = (*endp == '/') ? "/" : ".";
64 } while (endp > path && *endp == '/');
66 len = endp - path +1;
84 memcpy( buffer, path, len );