/system/netd/ |
H A D | NatController.cpp | 48 int NatController::runCmd(const char *path, const char *cmd) { argument 59 asprintf(&buffer, "%s %s", path, cmd);
|
/system/vold/ |
H A D | main.cpp | 38 static void coldboot(const char *path); 136 static void coldboot(const char *path) argument 138 DIR *d = opendir(path);
|
H A D | CommandListener.cpp | 137 cli->sendMsg(ResponseCode::CommandSyntaxError, "Usage: volume mount <path>", false); 145 cli->sendMsg(ResponseCode::CommandSyntaxError, "Usage: volume unmount <path> [force|force_and_revert]", false); 160 cli->sendMsg(ResponseCode::CommandSyntaxError, "Usage: volume format <path>", false); 167 "Usage: volume share <path> <method>", false); 174 "Usage: volume unshare <path> <method>", false); 182 "Usage: volume shared <path> <method>", false); 389 } else if (!strcmp(argv[1], "path")) { 392 cli->sendMsg(ResponseCode::CommandSyntaxError, "Usage: asec path <container-id>", false); 395 char path[255]; local 397 if (!(rc = vm->getAsecMountPath(argv[2], path, sizeo 407 char path[255]; local 471 char path[255]; local [all...] |
H A D | DirectVolume.cpp | 60 int DirectVolume::addPath(const char *path) { argument 61 mPaths->push_back(strdup(path)); 389 * This is to change the sysfs path associated with a partition, in particular, 394 SLOGE("Cannot change path if there are more than one for a volume\n"); 401 addPath(new_path); /* Put the new path on the list */
|
H A D | Volume.cpp | 66 * asec imagefiles. This path will be obscured before the mount is 199 int Volume::createDeviceNode(const char *path, int major, int minor) { argument 202 if (mknod(path, mode, dev) < 0) { 266 bool Volume::isMountpointMounted(const char *path) { argument 281 if (!strcmp(mount_path, path)) { 366 /* We now have the new sysfs path for the decrypted block device, and the 368 * path to the new sysfs path, and continue. 378 // Todo: Either create sys filename from nodepath, or pass in bogus path so 564 int Volume::doUnmount(const char *path, boo argument [all...] |
/system/core/adb/ |
H A D | adb_auth_host.c | 136 char path[PATH_MAX], info[MAX_PAYLOAD]; local 139 ret = snprintf(path, sizeof(path), "%s.pub", private_key_path); 140 if (ret >= (signed)sizeof(path)) 149 bfile = BIO_new_file(path, "w"); 151 D("Failed to open '%s'\n", path); 155 D("Writing public key to '%s'\n", path); 266 char path[PATH_MAX]; local 269 SHGetFolderPath(NULL, CSIDL_PROFILE, NULL, 0, path); 270 home = path; 299 char path[PATH_MAX]; local 324 char *path; local 383 char path[PATH_MAX]; local [all...] |
H A D | usb_vendors.c | 244 /* builds the path to the adb vendor id file. returns 0 if success */ 254 /* fills buff with the path to the adb vendor id file. returns 0 if success */ 262 char path[MAX_PATH]; local 263 SHGetFolderPath( NULL, CSIDL_PROFILE, NULL, 0, path); 264 return build_path(buff, len, "%s\\%s\\%s", path);
|
H A D | file_sync_client.c | 77 int sync_ls(int fd, const char *path, sync_ls_cb func, void *cookie) argument 83 len = strlen(path); 90 writex(fd, path, len)) { 126 int sync_readtime(int fd, const char *path, unsigned *timestamp) argument 129 int len = strlen(path); 135 writex(fd, path, len)) { 151 static int sync_start_readtime(int fd, const char *path) argument 154 int len = strlen(path); 160 writex(fd, path, len)) { 185 int sync_readmode(int fd, const char *path, unsigne argument 210 write_data_file(int fd, const char *path, syncsendbuf *sbuf) argument 273 write_data_link(int fd, const char *path, syncsendbuf *sbuf) argument 541 do_sync_ls(const char *path) argument [all...] |
H A D | sysdeps.h | 90 static __inline__ int adb_unlink(const char* path) argument 92 int rc = unlink(path); 97 rc = chmod(path, _S_IREAD|_S_IWRITE ); 99 rc = unlink(path); 106 static __inline__ int adb_mkdir(const char* path, int mode) argument 108 return _mkdir(path); 113 extern int adb_open(const char* path, int options); 114 extern int adb_creat(const char* path, int mode); 142 static __inline__ int adb_open_mode(const char* path, int options, int mode) argument 144 return adb_open(path, option 147 unix_open(const char* path, int options,...) argument 309 unix_open(const char* path, int options,...) argument 380 adb_unlink(const char* path) argument 387 adb_creat(const char* path, int mode) argument 471 adb_mkdir(const char* path, int mode) argument 482 adb_dirstart(const char* path) argument 487 adb_dirstop(const char* path) argument [all...] |
/system/core/cpio/ |
H A D | mkbootfs.c | 45 /* Each line in the canned file should be a path plus three ints (uid, 56 static void fix_stat(const char *path, struct stat *s) argument 68 if (strcmp(p->name, path) == 0) { 81 fs_config(path, S_ISDIR(s->st_mode), &s->st_uid, &s->st_gid, &s->st_mode);
|
/system/core/run-as/ |
H A D | package.c | 147 check_directory_ownership(const char* path, uid_t uid) argument 153 ret = lstat(path, &st); 179 /* This function is used to check the data directory path for safety. 182 * path is properly owned by the user ID. 191 /* the path should be absolute */ 198 * directory separators in the input path and 199 * checking each sub-path independently 430 * <dataDir> is the path to the package's data directory (e.g. /data/data/com.example.foo) 479 /* fourth field is data directory path and must not contain
|
/system/core/toolbox/ |
H A D | ls.c | 132 static int listfile_size(const char *path, const char *filename, int flags) argument 136 if (lstat(path, &s) < 0) { 137 fprintf(stderr, "lstat '%s' failed: %s\n", path, strerror(errno)); 152 if (!stat(path, &link_dest)) { 155 fprintf(stderr, "stat '%s' failed: %s\n", path, strerror(errno)); 166 static int listfile_long(const char *path, int flags) argument 175 /* name is anything after the final '/', or the whole path if none*/ 176 name = strrchr(path, '/'); 178 name = path; 183 if(lstat(path, 242 listfile_maclabel(const char *path, int flags) argument [all...] |
H A D | schedtop.c | 157 char path[1024]; local 160 sprintf(path, "/proc/%d/task", pid); 161 d = opendir(path);
|
/system/extras/fatblock/ |
H A D | import.c | 95 static int import_file(struct fs *fs, char *path, struct imported *out) argument 102 ret = stat(path, &st); 104 WARN("importing %s: stat failed: %s\n", path, strerror(errno)); 111 "out of memory\n", path); 116 path_copy = strdup(path); 118 WARN("importing %s: couldn't strdup path: out of memory\n", 119 path); 124 f->path = path_copy; 134 WARN("importing %s: couldn't allocate data extent\n", path); 193 static int import_dir(struct fs *fs, char *path, in argument 352 import_tree(struct fs *fs, char *path) argument [all...] |
/system/extras/tests/directiotest/ |
H A D | directiotest.c | 172 const char *path; local 186 path = argv[1]; 187 fd = open(path, O_RDWR | O_DIRECT | O_LARGEFILE); 196 fprintf(stderr, "%s is not a block device\n", path);
|
/system/extras/tests/sdcard/ |
H A D | sdcard_perf_test.cpp | 609 char path[MAX_PATH]; local 611 strcpy(path, kTestDir); 616 // Go deeper by appending onto current path 617 snprintf(path + strlen(path), MAX_PATH - strlen(path), "/dir%d", i); 618 mkdir(path, S_IRWXU); 621 strcpy(filepath, path); 622 int pathlen = strlen(path);
|
/system/core/debuggerd/ |
H A D | debuggerd.c | 160 char path[64]; local 161 snprintf(path, sizeof(path), "/proc/%d/status", tid); 163 FILE* fp = fopen(path, "r");
|
H A D | tombstone.c | 168 char path[64]; local 173 snprintf(path, sizeof(path), "/proc/%d/comm", tid); 174 if ((fp = fopen(path, "r"))) { 189 snprintf(path, sizeof(path), "/proc/%d/cmdline", pid); 190 if ((fp = fopen(path, "r"))) { 642 * Returns the path of the tombstone file, allocated using malloc(). Caller must free() it. 659 char path[128]; local 662 snprintf(path, sizeo 707 char* path = find_and_open_tombstone(&fd); local [all...] |
/system/core/include/private/ |
H A D | android_filesystem_config.h | 156 ** should start with the most specific path and work their 184 ** should start with the most specific path and work their 231 static inline void fs_config(const char *path, int dir, argument 238 plen = strlen(path); 243 if(!strncmp(pc->prefix, path, len)) break; 248 if(!strncmp(pc->prefix, path, len - 1)) break; 250 if(!strncmp(pc->prefix, path, len)) break; 259 path, pc->prefix ? pc->prefix : "", *uid, *gid, *mode);
|
/system/core/init/ |
H A D | property_service.c | 324 char path[PATH_MAX]; local 327 snprintf(path, sizeof(path), "%s/%s", PERSISTENT_PROPERTY_DIR, name); 337 if (rename(tempPath, path)) { 339 ERROR("Unable to rename persistent property file %s to %s\n", tempPath, path); 534 char path[PATH_MAX]; local 547 snprintf(path, sizeof(path), "%s/%s", PERSISTENT_PROPERTY_DIR, entry->d_name); 548 fd = open(path, O_RDONLY); 555 ERROR("Unable to read persistent property file %s errno: %d\n", path, errn [all...] |
H A D | util.c | 299 ERROR("path too long for mkdir_recursive\n"); 350 char path[256]; local 352 ret = readlink(newpath, path, sizeof(path) - 1); 355 path[ret] = 0; 356 if (!strcmp(path, oldpath)) 467 int make_dir(const char *path, mode_t mode) argument 475 selabel_lookup(sehandle, &secontext, path, mode); 480 rc = mkdir(path, mode);
|
H A D | builtins.c | 57 static int write_file(const char *path, const char *value) argument 61 fd = open(path, O_WRONLY|O_CREAT, 0622); 80 static int _open(const char *path) argument 84 fd = open(path, O_RDONLY | O_NOFOLLOW); 86 fd = open(path, O_WRONLY | O_NOFOLLOW); 91 static int _chown(const char *path, unsigned int uid, unsigned int gid) argument 96 fd = _open(path); 114 static int _chmod(const char *path, mode_t mode) argument 119 fd = _open(path); 299 /* mkdir <path> [mod 642 const char *path = args[1]; local [all...] |
/system/core/sh/ |
H A D | exec.c | 55 * This ensures that a full path search will not have to be done for them 99 STATIC int builtinloc = -1; /* index in path of %builtin, or -1 */ 119 shellexec(char **argv, char **envp, const char *path, int idx, int vforked) argument 129 while ((cmdname = padvance(&path, argv[0])) != NULL) { 280 * Do a path search. The variable path (passed by reference) should be 281 * set to the start of the path before the first call; padvance will update 283 * the possible path expansions in sequence. If an option (indicated by 284 * a percent sign) appears in the path entry then the global variable 292 padvance(const char **path, cons argument 380 const char *path; local 427 find_command(char *name, struct cmdentry *entry, int act, const char *path) argument 1008 const char *path = pathval(); local [all...] |
/system/bluetooth/brcm_patchram_plus/ |
H A D | brcm_patchram_plus.c | 100 ** set, then the bd_addr will be read from this path. 746 char path[PROPERTY_VALUE_MAX]; local 752 property_get("ro.bt.bdaddr_path", path, ""); 753 if (path[0] == 0) 756 fd = open(path, O_RDONLY); 758 fprintf(stderr, "open(%s) failed: %s (%d)", path, strerror(errno), 765 fprintf(stderr, "read(%s) failed: %s (%d)", path, strerror(errno), 770 fprintf(stderr, "read(%s) unexpected size %d", path, sz);
|
/system/core/fastboot/ |
H A D | fastboot.c | 90 void get_my_path(char *path); 96 char path[PATH_MAX + 128]; local 116 get_my_path(path); 117 sprintf(path + strlen(path), 119 return strdup(path); 128 sprintf(path, "%s/%s", dir, fn); 129 return strdup(path); 213 // require matching serial number or device path if requested 295 " or path t [all...] |