Searched defs:path (Results 1 - 25 of 59) sorted by relevance

123

/system/core/fastboot/
H A Dutil_linux.c37 void get_my_path(char *path) argument
43 int err = readlink(proc, path, PATH_MAX - 1);
46 path[0] = 0;
48 path[err] = 0;
49 x = strrchr(path,'/');
/system/core/toolbox/
H A Dload_policy.c16 const char *path; local
23 path = argv[1];
24 fd = open(path, O_RDONLY);
26 fprintf(stderr, "Could not open %s: %s\n", path, strerror(errno));
31 fprintf(stderr, "Could not stat %s: %s\n", path, strerror(errno));
37 fprintf(stderr, "Could not mmap %s: %s\n", path, strerror(errno));
43 fprintf(stderr, "Could not load %s: %s\n", path, strerror(errno));
H A Dchmod.c13 void recurse_chmod(char* path, int mode) argument
16 DIR *dir = opendir(path);
22 int pathlen = strlen(path);
29 fprintf(stderr, "Invalid path specified: too long\n");
33 strcpy(subpath, path);
H A Dmd5.c20 static int do_md5(const char *path) argument
27 fd = open(path, O_RDONLY);
29 fprintf(stderr,"could not open %s, %s\n", path, strerror(errno));
44 fprintf(stderr,"could not read %s, %s\n", path, strerror(errno));
50 fprintf(stderr,"could not close %s, %s\n", path, strerror(errno));
58 printf(" %s\n", path);
H A Dwipe.c28 static void wipe (const char *path);
81 static void wipe (const char *path) argument
87 dir = opendir(path);
91 path, strerror(errno));
97 strcpy(nameBuffer, path);
153 dir = opendir(path);
156 path, strerror(errno));
161 strcpy(nameBuffer, path);
H A Dumount.c28 static int is_loop_mount(const char* path, char *loopdev) argument
36 int path_length = strlen(path);
47 if (is_loop(device) && strcmp(path, mount_path) == 0) {
65 fprintf(stderr,"umount <path>\n");
H A Dlsof.c53 char path[PATH_MAX]; member in struct:pid_info_t
76 strncat(info->path, type, sizeof(info->path));
77 if ((link_dest_size = readlink(info->path, link_dest, sizeof(link_dest)-1)) < 0) {
81 snprintf(link_dest, sizeof(link_dest), "%s (readlink: %s)", info->path, strerror(errno));
95 info->path[info->parent_length] = '\0';
110 strncat(info->path, "maps", sizeof(info->path));
112 maps = fopen(info->path, "r");
130 info->path[inf
[all...]
/system/extras/ext4_utils/
H A Dcontents.h21 char *path; member in struct:dentry
H A Dsetup_fs.c14 char buf[256], path[128]; local
20 n = readlink(blockdev, path, sizeof(path) - 1);
22 path[n] = 0;
23 if (!memcmp(path, "/dev/block/", 11))
24 blockdev = path + 11;
H A Dmake_ext4fs_main.c40 static void usage(char *path) argument
42 fprintf(stderr, "%s [ -l <len> ] [ -j <journal size> ] [ -b <block_size> ]\n", basename(path));
H A Dext2simg.c46 static void usage(char *path) argument
48 fprintf(stderr, "%s [ options ] <image or block device> <output image>\n", path);
/system/core/libcutils/
H A Dfs.c33 int fs_prepare_dir(const char* path, mode_t mode, uid_t uid, gid_t gid) { argument
34 // Check if path needs to be created
36 if (TEMP_FAILURE_RETRY(lstat(path, &sb)) == -1) {
40 ALOGE("Failed to lstat(%s): %s", path, strerror(errno));
47 ALOGE("Not a directory: %s", path);
57 if (TEMP_FAILURE_RETRY(mkdir(path, mode)) == -1) {
59 ALOGE("Failed to mkdir(%s): %s", path, strerror(errno));
65 if (TEMP_FAILURE_RETRY(chmod(path, mode)) == -1) {
66 ALOGE("Failed to chmod(%s, %d): %s", path, mode, strerror(errno));
69 if (TEMP_FAILURE_RETRY(chown(path, ui
77 fs_read_atomic_int(const char* path, int* out_value) argument
102 fs_write_atomic_int(const char* path, int value) argument
[all...]
H A Ddir_hash.c36 * specified by path, using the specified algorithm. Returns the length
39 int get_file_hash(HashAlgorithm algorithm, const char *path, argument
52 if (stat(path, &sb) != 0) {
60 len = readlink(path, buf, sizeof(buf));
70 FILE *f = fopen(path, "rb");
/system/netd/
H A Dmain.cpp38 static void coldboot(const char *path);
135 static void coldboot(const char *path) argument
137 DIR *d = opendir(path);
/system/core/toolbox/grep/
H A Dfile.c235 grep_open(const char *path) argument
241 if (path == NULL) {
245 } else if ((f->fd = open(path, O_RDONLY)) == -1) {
/system/extras/fatblock/
H A Dfatblock.h46 char *path; member in struct:file
59 char *path; member in struct:dir
67 int import_tree(struct fs *fs, char *path);
H A Dfatblock.c151 char *path; local
162 DIE("Usage: fatblock <path> <size in MB>\n");
164 path = argv[1];
167 INFO("fatblock: importing filesystem from %s (%d MB)\n", path, mb);
169 ret = chdir(path);
171 DIE("fatblock: chdir(%s) failed: %s; aborting\n", path, strerror(errno));
/system/vold/
H A DProcess.cpp35 int Process::readSymLink(const char *path, char *link, size_t max) { argument
39 if (lstat(path, &s) < 0)
45 length = readlink(path, link, max- 1);
52 int Process::pathMatchesMountPoint(const char* path, const char* mountPoint) { argument
54 if (length > 1 && strncmp(path, mountPoint, length) == 0) {
59 // there is one in the path to avoid partial matches.
60 return (path[length] == 0 || path[length] == '/');
86 // compute path to process's directory of open files
87 char path[PATH_MA local
139 const char* path = strchr(buffer, '/'); local
155 char path[PATH_MAX]; local
180 killProcessesWithOpenFiles(const char *path, int action) argument
[all...]
/system/bluetooth/bluedroid/
H A Dbluetooth.c50 char path[64]; local
56 snprintf(path, sizeof(path), "/sys/class/rfkill/rfkill%d/type", id);
57 fd = open(path, O_RDONLY);
59 ALOGW("open(%s) failed: %s (%d)\n", path, strerror(errno), errno);
/system/core/adb/
H A Dadb_auth_client.c107 char *path; local
113 while ((path = *paths++)) {
114 if (!stat(path, &buf)) {
115 D("Loading keys from '%s'\n", path);
116 read_keys(path, &key_list);
H A Dfile_sync_service.c56 static int do_stat(int s, const char *path) argument
63 if(lstat(path, &st)) {
76 static int do_list(int s, const char *path) argument
87 len = strlen(path);
88 memcpy(tmp, path, len);
94 d = opendir(path);
151 static int handle_send_file(int s, char *path, mode_t mode, char *buffer) argument
157 fd = adb_open_mode(path, O_WRONLY | O_CREAT | O_EXCL, mode);
159 mkdirs(path);
160 fd = adb_open_mode(path, O_WRONL
227 handle_send_link(int s, char *path, char *buffer) argument
276 do_send(int s, char *path, char *buffer) argument
319 do_recv(int s, const char *path, char *buffer) argument
[all...]
/system/core/debuggerd/
H A Dbacktrace.c38 char path[PATH_MAX]; local
43 snprintf(path, sizeof(path), "/proc/%d/cmdline", pid);
44 if ((fp = fopen(path, "r"))) {
67 char path[PATH_MAX]; local
72 snprintf(path, sizeof(path), "/proc/%d/comm", tid);
73 if ((fp = fopen(path, "r"))) {
/system/core/libcorkscrew/
H A Dmap_info.c72 char path[PATH_MAX]; local
77 snprintf(path, PATH_MAX, "/proc/%d/maps", tid);
78 fp = fopen(path, "r");
/system/core/sh/
H A Dcd.c82 const char *path; local
122 if (*dest == '/' || (path = bltinlookup("CDPATH", 1)) == NULL)
123 path = nullstr;
124 while ((p = padvance(&path, dest)) != NULL) {
162 * Check each component of the path. If we find a symlink or
209 * Get the next component of the path name pointed to by cdcomppath.
H A Dmain.c332 * Take commands from a file. To be compatible we should do a path
341 const char *path = pathval(); local
348 while ((fullname = padvance(&path, basename)) != NULL) {

Completed in 79 milliseconds

123