Home
last modified time | relevance | path

Searched refs:path (Results 1 – 25 of 66) sorted by relevance

123

/bionic/libc/bionic/
Dlibgen.cpp42 static int __basename_r(const char* path, char* buffer, size_t buffer_size) { in __basename_r() argument
49 if (path == NULL || *path == '\0') { in __basename_r()
56 endp = path + strlen(path) - 1; in __basename_r()
57 while (endp > path && *endp == '/') { in __basename_r()
62 if (endp == path && *endp == '/') { in __basename_r()
70 while (startp > path && *(startp - 1) != '/') { in __basename_r()
95 __LIBC32_LEGACY_PUBLIC__ int basename_r(const char* path, char* buffer, size_t buffer_size) { in basename_r() argument
96 return __basename_r(path, buffer, buffer_size); in basename_r()
99 static int __dirname_r(const char* path, char* buffer, size_t buffer_size) { in __dirname_r() argument
105 if (path == NULL || *path == '\0') { in __dirname_r()
[all …]
Dlfs64_support.cpp23 int mkstemp64(char* path) { in mkstemp64() argument
24 return mkstemp(path); in mkstemp64()
26 int mkostemp64(char* path, int flags) { in mkostemp64() argument
27 return mkostemp(path, flags); in mkostemp64()
29 int mkstemps64(char* path, int suffix_length) { in mkstemps64() argument
30 return mkstemps(path, suffix_length); in mkstemps64()
32 int mkostemps64(char* path, int suffix_length, int flags) { in mkostemps64() argument
33 return mkostemps(path, suffix_length, flags); in mkostemps64()
Dmkfifo.cpp33 int mkfifo(const char* path, mode_t mode) { in mkfifo() argument
34 return mkfifoat(AT_FDCWD, path, mode); in mkfifo()
37 int mkfifoat(int fd, const char* path, mode_t mode) { in mkfifoat() argument
38 return mknodat(fd, path, (mode & ~S_IFMT) | S_IFIFO, 0); in mkfifoat()
D__gnu_basename.cpp32 extern "C" const char* __gnu_basename(const char* path) { in __gnu_basename() argument
33 const char* last_slash = strrchr(path, '/'); in __gnu_basename()
34 return (last_slash != NULL) ? last_slash + 1 : path; in __gnu_basename()
Dtmpfile.cpp60 char* path = NULL; in __tmpfile_dir() local
61 if (asprintf(&path, "%s/tmp.XXXXXXXXXX", tmp_dir) == -1) { in __tmpfile_dir()
68 fd = mkstemp(path); in __tmpfile_dir()
70 free(path); in __tmpfile_dir()
75 unlink(path); in __tmpfile_dir()
76 free(path); in __tmpfile_dir()
Dunlink.cpp32 int unlink(const char* path) { in unlink() argument
33 return unlinkat(AT_FDCWD, path, 0); in unlink()
Drmdir.cpp32 int rmdir(const char* path) { in rmdir() argument
33 return unlinkat(AT_FDCWD, path, AT_REMOVEDIR); in rmdir()
Daccess.cpp32 int access(const char* path, int mode) { in access() argument
33 return faccessat(AT_FDCWD, path, mode, 0); in access()
Dmkdir.cpp33 int mkdir(const char* path, mode_t mode) { in mkdir() argument
34 return mkdirat(AT_FDCWD, path, mode); in mkdir()
Dchmod.cpp33 int chmod(const char* path, mode_t mode) { in chmod() argument
34 return fchmodat(AT_FDCWD, path, mode, 0); in chmod()
Dstat.cpp34 int stat(const char* path, struct stat* sb) { in stat() argument
35 return fstatat(AT_FDCWD, path, sb, 0); in stat()
Dmknod.cpp34 int mknod(const char* path, mode_t mode, dev_t dev) { in mknod() argument
35 return mknodat(AT_FDCWD, path, mode, dev); in mknod()
/bionic/libc/upstream-openbsd/lib/libc/stdio/
Dmktemp.c45 mktemp_internal(char *path, int slen, int mode, int flags) in mktemp_internal() argument
54 len = strlen(path); in mktemp_internal()
59 ep = path + len - slen; in mktemp_internal()
61 for (start = ep; start > path && start[-1] == 'X'; start--) in mktemp_internal()
92 if (lstat(path, &sb) != 0) in mktemp_internal()
96 fd = open(path, flags, S_IRUSR|S_IWUSR); in mktemp_internal()
101 if (mkdir(path, S_IRUSR|S_IWUSR|S_IXUSR) == 0) in mktemp_internal()
116 _mktemp(char *path) in _mktemp() argument
118 if (mktemp_internal(path, 0, MKTEMP_NAME, 0) == -1) in _mktemp()
120 return(path); in _mktemp()
[all …]
/bionic/tests/
Dftw_test.cpp30 char path[PATH_MAX]; in MakeTree() local
32 snprintf(path, sizeof(path), "%s/dir", root); in MakeTree()
33 ASSERT_EQ(0, mkdir(path, 0755)) << path; in MakeTree()
34 snprintf(path, sizeof(path), "%s/dir/sub", root); in MakeTree()
35 ASSERT_EQ(0, mkdir(path, 0555)) << path; in MakeTree()
36 snprintf(path, sizeof(path), "%s/unreadable-dir", root); in MakeTree()
37 ASSERT_EQ(0, mkdir(path, 0000)) << path; in MakeTree()
39 snprintf(path, sizeof(path), "%s/dangler", root); in MakeTree()
40 ASSERT_EQ(0, symlink("/does-not-exist", path)); in MakeTree()
41 snprintf(path, sizeof(path), "%s/symlink", root); in MakeTree()
[all …]
/bionic/libc/tools/
Dgenerate-NOTICE.py17 def IsUninteresting(path): argument
18 path = path.lower()
19 …if path.endswith(".mk") or path.endswith(".py") or path.endswith(".pyc") or path.endswith(".txt") …
21 if path.endswith("/notice") or path.endswith("/readme") or path.endswith("/caveats"):
23 if path.endswith("/tzdata") or path.endswith("/zoneinfo/generate"):
116 path = os.path.join(directory, filename) variable
117 if IsUninteresting(path):
122 content = open(path, 'r').read().decode('utf-8')
124 sys.stderr.write('warning: bad UTF-8 in %s\n' % path)
125 content = open(path, 'r').read().decode('iso-8859-1')
[all …]
Dgenversion-scripts.py7 import os.path
13 bionic_libc_root = os.path.join(os.environ["ANDROID_BUILD_TOP"], "bionic/libc")
14 bionic_libm_root = os.path.join(os.environ["ANDROID_BUILD_TOP"], "bionic/libm")
15 bionic_libdl_root = os.path.join(os.environ["ANDROID_BUILD_TOP"], "bionic/libdl")
16 libc_script = os.path.join(bionic_libc_root, "libc.map.txt")
17 libm_script = os.path.join(bionic_libm_root, "libm.map.txt")
18 libdl_script = os.path.join(bionic_libdl_root, "libdl.map.txt")
27 bionic_libc_root = os.path.join(os.environ["ANDROID_BUILD_TOP"], "bionic/libc")
36 basename = os.path.basename(script)
37 dirname = os.path.dirname(script)
[all …]
Dsymbols.py59 lib_dir = os.path.join(out_dir, 'obj')
63 static_lib_dir = os.path.join(
66 '{}_intermediates'.format(os.path.splitext(f)[0]))
68 os.path.join(static_lib_dir, f),
75 lib_dir = os.path.join(out_dir, 'system/lib64')
76 if not os.path.isdir(lib_dir):
77 lib_dir = os.path.join(out_dir, 'system/lib')
81 results |= GetFromElf(os.path.join(lib_dir, f))
89 results |= GetFromElf(glob.glob(os.path.join(lib_dir, f))[-1])
Dgensyscalls.py12 import os.path
29 bionic_libc_root = os.path.join(os.environ["ANDROID_BUILD_TOP"], "bionic/libc")
35 def make_dir(path): argument
36 path = os.path.abspath(path)
37 if not os.path.exists(path):
38 parent = os.path.dirname(path)
41 os.mkdir(path)
45 full_path = os.path.join(bionic_temp, relpath)
46 dir = os.path.dirname(full_path)
560 def scan_linux_unistd_h(self, fp, path): argument
[all …]
/bionic/libc/kernel/tools/
Dkernel.py7 import sys, cpp, re, os.path, string, time
89 hdr_dir = os.path.realpath(os.path.dirname(from_file))
90 hdr_dir = hdr_dir.replace("%s/" % os.path.realpath(kernel_root),
106 def parseFile(self, path, arch=None, kernel_root=None): argument
108 if not os.path.exists(path):
115 f = open(path, "rt")
117 print "!!! can't read '%s'" % path
128 if verboseSearch: print "::: " + path
131 if verboseSearch: print "*** " + path
133 list = cpp.BlockParser().parseFile(path)
[all …]
Dutils.py11 sys.stderr.write(os.path.basename(sys.argv[0]) + ": error: ")
17 return os.path.join(get_android_root(), "external/kernel-headers")
21 return os.path.join(get_kernel_headers_dir(), "original")
25 return os.path.join(get_kernel_headers_dir(), "modified")
29 return os.path.join(get_android_root(), "bionic/libc/kernel")
50 def create_file_path(path): argument
53 parent = os.path.dirname(path)
58 path = parent
63 if os.path.isdir(dir):
75 def readFile(self,path): argument
[all …]
Dupdate_all.py24 """ % { "progname" : os.path.basename(sys.argv[0]) }
40 if not os.path.isdir(original_dir):
45 if not os.path.isdir(modified_dir):
49 if not os.path.isdir(original_dir):
52 if not os.path.isdir(modified_dir):
57 original_dir = os.path.normpath(original_dir)
61 _, ext = os.path.splitext(file)
63 rel_path = os.path.normpath(os.path.join(root, file))
66 if modified_dir and os.path.exists(os.path.join(modified_dir, rel_path)):
76 b.readDir(os.path.join(kernel_dir, "arch-%s" % arch))
[all …]
Dclean_header.py87 full_path = os.path.join(src_dir, rel_path)
89 if not os.path.exists(full_path):
93 if not os.path.isfile(full_path):
120 dst_path = os.path.join("common", rel_path)
122 dst_path = os.path.join(dst_dir, dst_path)
169 """ % os.path.basename(sys.argv[0])
196 for path in args:
197 dst_path, newdata = cleanupFile(dst_dir, src_dir, path)
206 for path in args:
207 dst_path, newdata = cleanupFile(dst_dir, src_dir, path, no_update)
[all …]
/bionic/libc/include/sys/
Dxattr.h39 extern int setxattr(const char *path, const char *name, const void *value, size_t size, int flags);
40 extern int lsetxattr(const char *path, const char *name, const void *value, size_t size, int flags);
43 extern ssize_t getxattr(const char *path, const char *name, void *value, size_t size);
44 extern ssize_t lgetxattr(const char *path, const char *name, void *value, size_t size);
46 extern ssize_t listxattr(const char *path, char *list, size_t size);
47 extern ssize_t llistxattr(const char *path, char *list, size_t size);
50 extern int removexattr(const char *path, const char *name);
51 extern int lremovexattr(const char *path, const char *name);
/bionic/linker/
Dlinker_utils.cpp20 bool normalize_path(const char* path, std::string* normalized_path) { in normalize_path() argument
22 if (path[0] != '/') { in normalize_path()
23 PRINT("normalize_path - invalid input: \"%s\", the input path should be absolute", path); in normalize_path()
27 const size_t len = strlen(path) + 1; in normalize_path()
30 const char* in_ptr = path; in normalize_path()
91 const char* const path = normalized_path.c_str(); in parse_zip_path() local
92 TRACE("Trying zip file open from path \"%s\" -> normalized \"%s\"", input_path, path); in parse_zip_path()
98 const char* const separator = strstr(path, kZipFileSeparator); in parse_zip_path()
104 if (strlcpy(buf, path, sizeof(buf)) >= sizeof(buf)) { in parse_zip_path()
105 PRINT("Warning: ignoring very long library path: %s", path); in parse_zip_path()
[all …]
/bionic/libc/upstream-netbsd/lib/libc/gen/
Dutime.c50 utime(const char *path, const struct utimbuf *times) in utime() argument
54 _DIAGASSERT(path != NULL); in utime()
64 return (utimes(path, tvp)); in utime()

123