Searched refs:path (Results 1 - 25 of 399) sorted by relevance

1234567891011>>

/system/tools/aidl/
H A Dimport_resolver.cpp36 for (string path : import_paths) {
37 if (path.empty()) {
38 path = ".";
40 if (path[path.size() - 1] != OS_PATH_SEPARATOR) {
41 path += OS_PATH_SEPARATOR;
43 import_paths_.push_back(std::move(path));
49 // Convert the canonical name to a relative file path.
58 // Look for that relative path at each of our import roots.
59 for (string path
[all...]
/system/vold/
H A DProcess.h24 static int killProcessesWithOpenFiles(const char *path, int signal);
26 static int checkSymLink(int pid, const char *path, const char *name);
27 static int checkFileMaps(int pid, const char *path);
28 static int checkFileMaps(int pid, const char *path, char *openFilename, size_t max);
33 static int readSymLink(const char *path, char *link, size_t max);
34 static int pathMatchesMountPoint(const char *path, const char *mountPoint);
39 void vold_killProcessesWithOpenFiles(const char *path, int signal);
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
173 vold_killProcessesWithOpenFiles(const char *path, int signal) argument
180 killProcessesWithOpenFiles(const char *path, int signal) argument
[all...]
/system/core/fastboot/
H A Dutil_linux.cpp39 void get_my_path(char *path) argument
45 int err = readlink(proc, path, PATH_MAX - 1);
48 path[0] = 0;
50 path[err] = 0;
51 x = strrchr(path,'/');
/system/core/include/cutils/
H A Dfs.h46 extern int fs_prepare_dir(const char* path, mode_t mode, uid_t uid, gid_t gid);
52 extern int fs_prepare_dir_strict(const char* path, mode_t mode, uid_t uid, gid_t gid);
58 extern int fs_prepare_file_strict(const char* path, mode_t mode, uid_t uid, gid_t gid);
65 extern int fs_read_atomic_int(const char* path, int* value);
71 extern int fs_write_atomic_int(const char* path, int value);
74 * Ensure that all directories along given path exist, creating parent
75 * directories as needed. Validates that given path is absolute and that
76 * it contains no relative "." or ".." paths or symlinks. Last path segment
77 * is treated as filename and ignored, unless the path ends with "/".
79 extern int fs_mkdirs(const char* path, mode_
[all...]
/system/connectivity/shill/cellular/
H A Dmock_modem.cc22 const std::string& path,
25 : Modem(service, path, modem_info, control_interface) {}
21 MockModem(const std::string& service, const std::string& path, ModemInfo* modem_info, ControlInterface* control_interface) argument
H A Dmodem_manager.cc37 const string& path,
41 path_(path),
68 bool ModemManager::ModemExists(const std::string& path) const {
70 if (ContainsKey(modems_, path)) {
71 LOG(INFO) << "ModemExists: " << path << " already exists.";
79 modems_[modem->path()] = modem;
82 void ModemManager::RemoveModem(const string& path) { argument
83 LOG(INFO) << "Remove modem: " << path;
85 modems_.erase(path);
98 const string& path,
35 ModemManager(ControlInterface* control_interface, const string& service, const string& path, ModemInfo* modem_info) argument
95 ModemManagerClassic( ControlInterface* control_interface, const string& service, const string& path, ModemInfo* modem_info) argument
136 AddModemClassic(const string& path) argument
167 OnDeviceAdded(const string& path) argument
171 OnDeviceRemoved(const string& path) argument
[all...]
/system/extras/ext4_utils/
H A Dext4_crypt_init_extensions.h26 int e4crypt_create_device_key(const char* path,
28 int e4crypt_set_directory_policy(const char* path);
/system/connectivity/shill/
H A Dstore_factory.cc41 StoreInterface* StoreFactory::CreateStore(const base::FilePath& path) { argument
43 return new JsonStore(path);
45 return new KeyFileStore(path);
H A Dfile_reader_unittest.cc35 void VerifyReadLines(const FilePath& path, const vector<string>& lines) { argument
38 EXPECT_TRUE(reader_.Open(path));
59 FilePath path; local
60 ASSERT_TRUE(base::CreateTemporaryFileInDir(temp_dir.path(), &path));
62 EXPECT_TRUE(reader_.Open(path));
78 FilePath path; local
79 ASSERT_TRUE(base::CreateTemporaryFileInDir(temp_dir.path(), &path));
83 base::WriteFile(path, conten
[all...]
H A Dshill_test_config.cc35 return dir_.path().value();
39 return dir_.path().value();
H A Dmock_control.h93 DBusPropertiesProxyInterface*(const std::string& path,
98 const std::string& path,
105 const std::string& path,
110 ModemProxyInterface*(const std::string& path,
113 ModemSimpleProxyInterface*(const std::string& path,
117 ModemCDMAProxyInterface*(const std::string& path,
120 ModemGSMCardProxyInterface*(const std::string& path,
123 ModemGSMNetworkProxyInterface*(const std::string& path,
126 ModemGobiProxyInterface*(const std::string& path,
129 mm1::ModemModem3gppProxyInterface*(const std::string& path,
[all...]
/system/update_engine/payload_consumer/
H A Dfile_writer_unittest.cc41 string path; local
42 ASSERT_TRUE(utils::MakeTempFile("FileWriterTest-XXXXXX", &path, nullptr));
43 ScopedPathUnlinker path_unlinker(path);
46 EXPECT_EQ(0, file_writer.Open(path.c_str(),
51 EXPECT_TRUE(utils::ReadFile(path, &actual_data));
59 const string path("/tmp/ENOENT/FileWriterTest");
60 EXPECT_EQ(-ENOENT, file_writer.Open(path.c_str(),
66 string path; local
67 ASSERT_TRUE(utils::MakeTempFile("FileWriterTest-XXXXXX", &path, nullptr));
68 ScopedPathUnlinker path_unlinker(path);
[all...]
/system/tpm/tpm_manager/server/
H A Dlocal_data_store_impl.cc36 FilePath path(kTpmLocalDataFile);
37 if (!base::PathExists(path)) {
42 if (base::GetPosixFilePermissions(path, &permissions) &&
44 base::SetPosixFilePermissions(path, kLocalDataPermissions);
47 if (!ReadFileToString(path, &file_data)) {
64 FilePath path(kTpmLocalDataFile);
65 if (!base::CreateDirectory(path.DirName())) {
66 LOG(ERROR) << "Cannot create directory: " << path.DirName().value();
69 if (!base::ImportantFileWriter::WriteFileAtomically(path, file_data)) {
70 LOG(ERROR) << "Failed to write file: " << path
[all...]
/system/core/libprocessgroup/
H A Dprocessgroup.cpp87 static int convertUidToPath(char *path, size_t size, uid_t uid) argument
89 return snprintf(path, size, "%s/%s%d",
95 static int convertUidPidToPath(char *path, size_t size, uid_t uid, int pid) argument
97 return snprintf(path, size, "%s/%s%d/%s%d",
108 char path[PROCESSGROUP_MAX_PATH_LEN] = {0}; local
109 convertUidPidToPath(path, sizeof(path), uid, pid);
110 strlcat(path, PROCESSGROUP_CGROUP_PROCS_FILE, sizeof(path));
112 int fd = open(path, O_RDONL
191 char path[PROCESSGROUP_MAX_PATH_LEN] = {0}; local
209 char path[PROCESSGROUP_MAX_PATH_LEN]; local
238 char path[PROCESSGROUP_MAX_PATH_LEN]; local
321 mkdirAndChown(const char *path, mode_t mode, uid_t uid, gid_t gid) argument
342 char path[PROCESSGROUP_MAX_PATH_LEN] = {0}; local
[all...]
/system/core/healthd/
H A DBatteryMonitor.cpp127 int BatteryMonitor::readFromFile(const String8& path, char* buf, size_t size) { argument
130 if (path.isEmpty())
132 int fd = open(path.string(), O_RDONLY, 0);
134 KLOG_ERROR(LOG_TAG, "Could not open '%s'\n", path.string());
151 BatteryMonitor::PowerSupplyType BatteryMonitor::readPowerSupplyType(const String8& path) { argument
154 int length = readFromFile(path, buf, SIZE);
185 bool BatteryMonitor::getBooleanField(const String8& path) { argument
190 if (readFromFile(path, buf, SIZE) > 0) {
199 int BatteryMonitor::getIntField(const String8& path) { argument
204 if (readFromFile(path, bu
267 String8 path; local
487 String8 path; local
[all...]
/system/core/init/
H A Dinit_parser.cpp95 bool Parser::ParseConfigFile(const std::string& path) { argument
96 INFO("Parsing file %s...\n", path.c_str());
99 if (!read_file(path.c_str(), &data)) {
104 ParseData(path, data);
106 sp.second->EndFile(path);
113 NOTICE("(Parsing %s took %.2fs.)\n", path.c_str(), t.duration());
117 bool Parser::ParseConfigDir(const std::string& path) { argument
118 INFO("Parsing directory %s...\n", path.c_str());
119 std::unique_ptr<DIR, int(*)(DIR*)> config_dir(opendir(path.c_str()), closedir);
121 ERROR("Could not import directory '%s'\n", path
138 ParseConfig(const std::string& path) argument
[all...]
/system/core/libcutils/
H A Dcanned_fs_config.c28 const char* path; member in struct:__anon1608
40 return strcmp(((Path*)a)->path, ((Path*)b)->path);
57 p->path = strdup(strtok(line, " "));
85 void canned_fs_config(const char* path, int dir, const char* target_out_path, argument
88 key.path = path;
89 if (path[0] == '/')
90 key.path++; // canned paths lack the leading '/'
93 fprintf(stderr, "failed to find [%s] in canned fs_config\n", path);
[all...]
H A Dfs.c40 static int fs_prepare_path_impl(const char* path, mode_t mode, uid_t uid, gid_t gid, argument
42 // Check if path needs to be created
45 if (TEMP_FAILURE_RETRY(lstat(path, &sb)) == -1) {
49 ALOGE("Failed to lstat(%s): %s", path, strerror(errno));
57 ALOGE("Not a %s: %s", (prepare_as_dir ? "directory" : "regular file"), path);
69 ALOGE("Expected path %s with owner %d:%d but found %d:%d",
70 path, uid, gid, sb.st_uid, sb.st_gid);
73 ALOGW("Expected path %s with mode %o but found %o",
74 path, mode, (sb.st_mode & ALL_PERMS));
81 ? TEMP_FAILURE_RETRY(mkdir(path, mod
108 fs_prepare_dir(const char* path, mode_t mode, uid_t uid, gid_t gid) argument
112 fs_prepare_dir_strict(const char* path, mode_t mode, uid_t uid, gid_t gid) argument
116 fs_prepare_file_strict(const char* path, mode_t mode, uid_t uid, gid_t gid) argument
120 fs_read_atomic_int(const char* path, int* out_value) argument
145 fs_write_atomic_int(const char* path, int value) argument
189 fs_mkdirs(const char* path, mode_t mode) argument
[all...]
/system/connectivity/shill/test-scripts/
H A Drm-service6 print "Usage: %s <service-path>" % (sys.argv[0])
9 (_, path) = sys.argv
13 service = flim.FindElementByNameSubstring("Service", path)
H A Dshow-introspection15 for path in properties["Devices"]:
16 device = dbus.Interface(bus.get_object("org.chromium.flimflam", path),
21 bus.get_object("org.chromium.flimflam", path),
/system/connectivity/shill/wimax/
H A Dmock_wimax.cc32 const RpcIdentifier& path)
34 interface_index, path) {
25 MockWiMax(ControlInterface* control, EventDispatcher* dispatcher, Metrics* metrics, Manager* manager, const string& link_name, const string& address, int interface_index, const RpcIdentifier& path) argument
/system/core/base/
H A Dtest_utils.cpp63 CHECK_LT(result, sizeof(tmp_dir)) << "path truncated to: " << result;
65 // GetTempPath() returns a path with a trailing slash, but init()
81 unlink(path);
85 snprintf(path, sizeof(path), "%s%cTemporaryFile-XXXXXX", tmp_dir.c_str(),
87 fd = mkstemp(path);
95 rmdir(path);
99 snprintf(path, sizeof(path), "%s%cTemporaryDir-XXXXXX", tmp_dir.c_str(),
101 return (mkdtemp(path) !
[all...]
/system/update_engine/
H A Dfake_shill_proxy.cc32 const dbus::ObjectPath& path) {
33 auto it = service_proxy_mocks_.find(path.value());
35 << path.value();
42 const dbus::ObjectPath& path,
44 service_proxy_mocks_[path.value()] = std::move(service_proxy);
31 GetServiceForPath( const dbus::ObjectPath& path) argument
41 SetServiceForPath( const dbus::ObjectPath& path, std::unique_ptr<ServiceProxyInterface> service_proxy) argument
/system/bt/service/
H A Dsettings.cpp42 // socket path for IPC.
43 base::FilePath path(iter.second);
44 if (path.empty() || path.EndsWithSeparator()) {
45 LOG(ERROR) << "Invalid IPC create socket path";
49 create_ipc_socket_path_ = path;

Completed in 636 milliseconds

1234567891011>>