Searched refs:path (Results 1 - 25 of 318) sorted by relevance

1234567891011>>

/ast/src/lib/libast/comp/
H A Dgetwd.c32 getwd(char* path) argument
34 if (getcwd(path, PATH_MAX)) return(path);
35 strcpy(path, "getwd: error in . or ..");
H A Dunlink.c33 unlink(const char* path)
35 return(remove(path));
H A Dlstat.c34 lstat(const char* path, struct stat* st)
36 return(stat(path, st));
H A Dresolvepath.c44 resolvepath(const char* file, char* path, size_t size) argument
62 s = path;
63 else if (!getcwd(path, size - n))
67 s = path + strlen(path);
70 strlcpy(s, file, size - (s - path));
71 return (s = pathcanon(path, size, PATH_PHYSICAL|PATH_DOTDOT|PATH_EXISTS)) ? (s - path) : -1;
H A Dcreat64.c33 creat64(const char* path, mode_t mode)
35 return open64(path, O_WRONLY|O_CREAT|O_TRUNC, mode);
H A Dexecvpe.c48 register const char* path = name;
51 if (*path != '/' && !(path = pathpath(name, NULL, PATH_REGULAR|PATH_EXECUTE, buffer, sizeof(buffer))))
52 path = name;
53 execve(path, argv, envv);
65 *nv++ = (char*)path;
68 path = pathshell();
69 execve(path, newargv, envv);
H A Dgross.c44 extern int lstat(const char* path, struct stat* st) argument
47 return __lxstat(_STAT_VER, path, st);
49 return _lxstat(_STAT_VER, path, st);
53 extern int stat(const char* path, struct stat* st) argument
56 return __xstat(_STAT_VER, path, st);
58 return _xstat(_STAT_VER, path, st);
75 extern int lstat64(const char* path, struct stat64* st) argument
78 return __lxstat64(_STAT_VER, path, st);
80 return _lxstat64(_STAT_VER, path, st);
84 extern int stat64(const char* path, struc argument
[all...]
H A Drealpath.c45 realpath(const char* file, char* path) argument
47 return resolvepath(file, path, PATH_MAX) > 0 ? path : (char*)0;
/ast/src/cmd/3d/
H A Dexecv.c27 execv(const char* path, char* const argv[]) argument
29 return(execve(path, argv, environ));
H A Dcreat3d.c27 creat3d(const char* path, mode_t mode) argument
29 return(open(path, O_WRONLY|O_CREAT|O_TRUNC, mode));
H A Dreadlink3d.c27 readlink3d(const char* path, char* buf, register size_t size) argument
35 return(READLINK(path, buf, size));
37 if (!fscall(NiL, MSG_readlink, 0, path, buf, size))
41 if (!pathreal(path, P_READLINK, NiL))
48 if (r = state.path.linksize)
50 if (r > state.path.linksize)
51 r = state.path.linksize;
52 memcpy(buf, state.path.linkname, r);
54 if (mp) fscall(mp, MSG_readlink, r, path, buf, size);
57 fscall(mp, MSG_readlink, r, path, bu
[all...]
H A Dunlink3d.c27 unlink3d(register const char* path) argument
34 if (!fscall(NiL, MSG_remove, 0, path))
38 if (!(sp = pathreal(path, P_PATHONLY|P_SAFE, NiL)))
40 if (state.path.level)
42 if (!(r = LSTAT(sp, &state.path.st)))
44 if (S_ISLNK(state.path.st.st_mode) && !checklink(sp, &state.path.st, P_PATHONLY|P_LSTAT) && state.path.linksize > 0)
60 fscall(mp, MSG_remove, 0, path);
63 fscall(mp, MSG_remove, 0, path);
74 remove(const char* path) argument
[all...]
/ast/src/lib/libast/stdio/
H A Dfopen.c27 fopen(const char* path, const char* mode) argument
29 return sfopen(NiL, path, mode);
H A Dfreopen.c27 freopen(const char* path, const char* mode, Sfio_t* f) argument
29 STDIO_PTR(f, "freopen", Sfio_t*, (const char*, const char*, Sfio_t*), (path, mode, f))
31 return sfopen(f, path, mode);
/ast/src/lib/libast/path/
H A Dpathrepl.c27 * in place replace of first occurrence of /match/ with /replace/ in path
28 * end of path returned
36 pathrepl(char* path, const char* match, const char* replace) argument
38 return pathrepl_20100601(path, PATH_MAX, match, replace);
46 pathrepl_20100601(register char* path, size_t size, const char* match, register const char* replace) argument
57 return(path + strlen(path));
59 size = strlen(path) + 1;
62 while (*path && *path
[all...]
H A Dpathnative.c27 * convert path to native fs representation in <buf,siz>
28 * length of converted path returned
41 pathnative(const char* path, char* buf, size_t siz) argument
43 return uwin_path(path, buf, siz);
53 pathnative(const char* path, char* buf, size_t siz) argument
61 cygwin_conv_to_win32_path(path, tmp);
66 cygwin_conv_to_win32_path(path, buf);
75 pathnative(const char* path, char* buf, size_t siz) argument
80 if (!_fullpath(buf, path, siz))
86 else if ((n = strlen(path)) < si
98 pathnative(const char* path, char* buf, size_t siz) argument
111 pathnative(const char* path, char* buf, size_t siz) argument
[all...]
H A Dpathposix.c27 * convert native path to posix fs representation in <buf,siz>
28 * length of converted path returned
41 pathposix(const char* path, char* buf, size_t siz) argument
43 return uwin_unpath(path, buf, siz);
53 pathposix(const char* path, char* buf, size_t siz) argument
61 cygwin_conv_to_posix_path(path, tmp);
66 cygwin_conv_to_posix_path(path, buf);
75 pathposix(const char* path, char* buf, size_t siz) argument
80 if (!_posixpath(buf, path, siz))
86 else if ((n = strlen(path)) < si
98 pathposix(const char* path, char *buf, size_t siz) argument
113 pathposix(const char* path, char* buf, size_t siz) argument
[all...]
H A Dpathstat.c33 pathstat(const char* path, struct stat* st) argument
39 if (!stat(path, st)) return(0);
41 return(lstat(path, st));
43 return(stat(path, st));
H A Dpathaccess.c27 * return path to file a/b with access mode using : separated dirs
30 * if (mode&PATH_REGULAR) then path must not be a directory
31 * if (mode&PATH_ABSOLUTE) then path must be rooted
32 * path returned in path buffer
40 pathaccess(char* path, const char* dirs, const char* a, const char* b, int mode) argument
42 return pathaccess_20100601(dirs, a, b, mode, path, PATH_MAX);
50 pathaccess_20100601(register const char* dirs, const char* a, const char* b, register int mode, register char* path, size_t size) argument
58 dirs = pathcat(dirs, sep, a, b, path, size);
59 pathcanon(path, siz
[all...]
H A Dpathprog.c27 * return the full path of the current program in path
47 prog(const char* command, char* path, size_t size) argument
62 if ((n = readlink(_PROC_PROG, path, size)) > 0 && *path == '/')
65 path[n] = 0;
75 if (!_NSGetExecutablePath(path, &z) && *path == '/')
76 return strlen(path);
83 t = path;
117 pathprog(const char* command, char* path, size_t size) argument
[all...]
H A Dpathpath.c27 * return full path to p with mode access using $PATH
32 * full path returned in path buffer
33 * if path==0 then the space is malloc'd
41 pathpath(char* path, const char* p, const char* a, int mode) argument
43 return pathpath_20100601(p, a, mode, path, PATH_MAX);
51 pathpath_20100601(const char* p, const char* a, int mode, register char* path, size_t size) argument
59 if (!path)
61 path = buf;
74 strcpy(path,
[all...]
/ast/src/lib/libdll/
H A Ddllcheck.c31 * path!=0 enables library level diagnostics
35 dllversion(void* dll, const char* path) argument
41 if (path)
45 errorf("dll", NiL, 1, "dllversion: %s: %s", path, state.errorbuf);
51 * check if dll on path has plugin version >= ver
53 * path!=0 enables library level diagnostics
58 dllcheck(void* dll, const char* path, unsigned long ver, unsigned long* cur) argument
65 v = dllversion(dll, path);
75 if (path)
79 errorf("dll", NiL, 1, "dllcheck: %s: %s", path, stat
[all...]
/ast/src/lib/libcoshell/
H A Dprocrun.c33 coprocrun(const char* path, char** argv, int flags) argument
41 return procclose(procopen(path, a, NiL, NiL, PROC_FOREGROUND|PROC_GID|PROC_UID|flags));
44 sfputr(tmp, path ? path : "sh", -1);
/ast/src/lib/libast/misc/
H A Dprocrun.c37 procrun(const char* path, char** argv, int flags) argument
46 return pathpath(path, NiL, PATH_REGULAR|PATH_EXECUTE, buf, sizeof(buf)) ? 0 : -1;
48 return procclose(procopen(path, argv, NiL, NiL, flags|PROC_FOREGROUND|PROC_GID|PROC_UID));
/ast/src/lib/libast/preroot/
H A Drealopen.c25 * disable preroot and open path relative to the real root
34 realopen(const char* path, int mode, int perm) argument
38 if (*path != '/' || !ispreroot(NiL)) return(-1);
39 strcopy(strcopy(buf, PR_REAL), path);

Completed in 69 milliseconds

1234567891011>>