Home | History | Annotate | Download | only in installd

Lines Matching full:path

180 static int is_valid_apk_path(const char *path)
184 if (strncmp(path, APK_DIR_PREFIX, len)) {
186 if (strncmp(path, PROTECTED_DIR_PREFIX, len)) {
188 if (strncmp(path, SDCARD_DIR_PREFIX, len)) {
189 LOGE("invalid apk path '%s' (bad prefix)\n", path);
196 if ((nosubdircheck != 1) && strchr(path + len, '/')) {
197 LOGE("invalid apk path '%s' (subdir?)\n", path);
200 if (path[len] == '.') {
201 LOGE("invalid apk path '%s' (trickery)\n", path);
226 int rm_dex(const char *path)
230 if (!is_valid_apk_path(path)) return -1;
231 if (create_cache_path(dex_path, path)) return -1;
323 char path[PKG_PATH_MAX];
346 if (!create_cache_path(path, apkpath)) {
347 if (stat(path, &s) == 0) {
352 if (create_pkg_path(path, PKG_DIR_PREFIX, pkgname, PKG_DIR_POSTFIX)) {
356 d = opendir(path);
403 int create_cache_path(char path[PKG_PATH_MAX], const char *src)
411 /* demand that we are an absolute path */
427 sprintf(path,"%s%s%s",
432 for(tmp = path + strlen(DALVIK_CACHE_PREFIX); *tmp; tmp++) {
595 int create_move_path(char path[PKG_PATH_MAX],
604 sprintf(path, "%s%s/%s", prefix, pkgname, leaf);
608 void mkinnerdirs(char* path, int basepos, mode_t mode, int uid, int gid,
611 while (path[basepos] != 0) {
612 if (path[basepos] == '/') {
613 path[basepos] = 0;
614 if (lstat(path, statbuf) < 0) {
615 LOGI("Making directory: %s\n", path);
616 path, mode) == 0) {
617 chown(path, uid, gid);
619 LOGW("Unable to make directory %s: %s\n", path, strerror(errno));
622 path[basepos] = '/';
679 LOGW("Source path too long; skipping: %s/%s\n", srcpath, name);
684 LOGW("Destination path too long; skipping: %s/%s\n", dstpath, name);
766 LOGW("Path before package line in %s%s: %s\n",
810 LOGW("Can't create path %s in %s%s\n",
828 LOGW("Can't create path %s in %s%s\n",