Home
last modified time | relevance | path

Searched refs:dex_path (Results 1 – 7 of 7) sorted by relevance

/frameworks/native/cmds/installd/
Ddexopt.cpp1151 static bool validate_dex_path_size(const std::string& dex_path) { in validate_dex_path_size() argument
1152 if (dex_path.size() >= (PKG_PATH_MAX - 8)) { in validate_dex_path_size()
1153 LOG(ERROR) << "dex_path too long: " << dex_path; in validate_dex_path_size()
1363 const std::string& dex_path, const char* profile_name, bool profile_guided, in maybe_open_reference_profile() argument
1386 location = dex_path; in maybe_open_reference_profile()
1638 static bool prepare_secondary_dex_oat_dir(const std::string& dex_path, int uid, in prepare_secondary_dex_oat_dir() argument
1640 unsigned long dirIndex = dex_path.rfind('/'); in prepare_secondary_dex_oat_dir()
1642 LOG(ERROR ) << "Unexpected dir structure for secondary dex " << dex_path; in prepare_secondary_dex_oat_dir()
1645 std::string dex_dir = dex_path.substr(0, dirIndex); in prepare_secondary_dex_oat_dir()
1650 LOG(ERROR) << "Could not prepare oat dir for secondary dex: " << dex_path; in prepare_secondary_dex_oat_dir()
[all …]
Dutils.cpp247 static bool get_secondary_dex_location(const std::string& dex_path, in get_secondary_dex_location() argument
249 size_t dirIndex = dex_path.rfind('/'); in get_secondary_dex_location()
253 if (dirIndex == dex_path.size() - 1) { in get_secondary_dex_location()
256 *out_dir_name = dex_path.substr(0, dirIndex); in get_secondary_dex_location()
257 *out_file_name = dex_path.substr(dirIndex + 1); in get_secondary_dex_location()
815 bool validate_secondary_dex_path(const std::string& pkgname, const std::string& dex_path, in validate_secondary_dex_path() argument
820 if (dex_path.empty()) { return false; } in validate_secondary_dex_path()
822 if (dex_path[0] != '/') { return false; } in validate_secondary_dex_path()
824 if (dex_path[dex_path.size() - 1] == '/') { return false; } in validate_secondary_dex_path()
826 if (dex_path.find("/.") != std::string::npos) { return false; } in validate_secondary_dex_path()
[all …]
Ddexopt.h96 bool reconcile_secondary_dex_file(const std::string& dex_path,
101 bool hash_secondary_dex_file(const std::string& dex_path,
Dutils.h126 bool validate_secondary_dex_path(const std::string& pkgname, const std::string& dex_path,
DInstalldNativeService.cpp1183 char dex_path[PKG_PATH_MAX]; in rmdex() local
1192 if (!create_cache_path(dex_path, path, instruction_set)) { in rmdex()
1196 ALOGV("unlink %s\n", dex_path); in rmdex()
1197 if (unlink(dex_path) < 0) { in rmdex()
1201 return error(StringPrintf("Failed to unlink %s", dex_path)); in rmdex()
/frameworks/native/cmds/installd/tests/
Dinstalld_utils_test.cpp423 const std::string& dex_path, int uid, int storage_flag) { in pass_secondary_dex_validation() argument
424 EXPECT_TRUE(validate_secondary_dex_path(package_name, dex_path, /*volume_uuid*/ nullptr, uid, in pass_secondary_dex_validation()
426 << dex_path << " should be allowed as a valid secondary dex path"; in pass_secondary_dex_validation()
430 const std::string& dex_path, int uid, int storage_flag) { in fail_secondary_dex_validation() argument
431 EXPECT_FALSE(validate_secondary_dex_path(package_name, dex_path, /*volume_uuid*/ nullptr, uid, in fail_secondary_dex_validation()
433 << dex_path << " should not be allowed as a valid secondary dex path"; in fail_secondary_dex_validation()
Dinstalld_dexopt_test.cpp449 const std::string& dex_path, in GetPrimaryDexArtifact() argument
452 std::string path = dex_path; in GetPrimaryDexArtifact()
461 std::string::size_type name_end = dex_path.rfind('.'); in GetPrimaryDexArtifact()
462 std::string::size_type name_start = dex_path.rfind('/'); in GetPrimaryDexArtifact()
464 dex_path.substr(name_start + 1, name_end - name_start) + type; in GetPrimaryDexArtifact()