Home
last modified time | relevance | path

Searched refs:ParseInt (Results 1 – 25 of 56) sorted by relevance

123

/system/libbase/
Dparseint_test.cpp26 ASSERT_FALSE(android::base::ParseInt("x", &i)); in TEST()
29 ASSERT_FALSE(android::base::ParseInt("123x", &i)); in TEST()
32 ASSERT_TRUE(android::base::ParseInt("123", &i)); in TEST()
36 EXPECT_TRUE(android::base::ParseInt(" 123", &i)); in TEST()
38 ASSERT_TRUE(android::base::ParseInt("-123", &i)); in TEST()
41 EXPECT_TRUE(android::base::ParseInt(" -123", &i)); in TEST()
45 ASSERT_TRUE(android::base::ParseInt("1234", &s)); in TEST()
48 ASSERT_TRUE(android::base::ParseInt("12", &i, 0, 15)); in TEST()
51 ASSERT_FALSE(android::base::ParseInt("-12", &i, 0, 15)); in TEST()
54 ASSERT_FALSE(android::base::ParseInt("16", &i, 0, 15)); in TEST()
[all …]
/system/core/init/
Dproperty_type.cpp24 using android::base::ParseInt;
51 return ParseInt(value, &parsed); in CheckType()
Drlimit_parser.cpp23 using android::base::ParseInt;
41 if (ParseInt(args[1], &resource)) { in ParseRlimit()
Dservice_parser.cpp46 using android::base::ParseInt;
139 if (!ParseInt(args[1], &service_->proc_attr_.priority, in ParsePriority()
184 if (!ParseInt(args[2], &service_->proc_attr_.ioprio_pri, 0, 7)) { in ParseIoprio()
221 if (ParseInt(*it, &code, 0, KEY_MAX)) { in ParseKeycodes()
265 if (!ParseInt(args[1], &service_->oom_score_adjust_, MIN_OOM_SCORE_ADJUST, in ParseOomScoreAdjust()
279 if (!ParseInt(args[1], &service_->swappiness_, 0)) { in ParseMemcgSwappiness()
286 if (!ParseInt(args[1], &service_->limit_in_bytes_, 0)) { in ParseMemcgLimitInBytes()
293 if (!ParseInt(args[1], &service_->limit_percent_, 0)) { in ParseMemcgLimitPercent()
305 if (!ParseInt(args[1], &service_->soft_limit_in_bytes_, 0)) { in ParseMemcgSoftLimitInBytes()
333 if (!ParseInt(args[1], &period, 5)) { in ParseRestartPeriod()
[all …]
Dcheck_builtins.cpp40 using android::base::ParseInt;
119 ParseInt(args[1], &log_level); in check_loglevel()
217 if (!android::base::ParseInt(args[1], &tz.tz_minuteswest)) { in check_sysclktz()
Dhost_init_verifier.cpp54 using android::base::ParseInt;
78 if (!ParseInt(split_line[2], &uid)) { in GetVendorPasswd()
/system/core/libkeyutils/mini_keyctl/
Dmini_keyctl_utils.cpp48 if (android::base::ParseInt(keyring_desc.c_str(), &keyring_id)) { in GetKeyringId()
74 if (!android::base::ParseInt(key_id.c_str(), &keyring_id)) { in GetKeyringId()
Dmini_keyctl.cpp51 if (!android::base::ParseInt(str, &key)) { in parseKeyOrDie()
/system/libbase/include/android-base/
Dparseint.h98 bool ParseInt(const char* s, T* out,
129 bool ParseInt(const std::string& s, T* out,
132 return ParseInt(s.c_str(), out, min, max);
/system/core/fs_mgr/
Dfs_mgr_fstab.cpp42 using android::base::ParseInt;
134 if (!ParseInt(arg, &entry->reserved_size)) { in ParseMountFlags()
204 if (!ParseInt(parts[1], &entry->partnum)) { in ParseFsMgrFlags()
212 if (!ParseInt(arg, &entry->length)) { in ParseFsMgrFlags()
216 if (!ParseInt(arg, &entry->swap_prio)) { in ParseFsMgrFlags()
223 if (ParseInt(arg, &val, 0, 100)) { in ParseFsMgrFlags()
229 if (!ParseInt(arg, &entry->zram_size)) { in ParseFsMgrFlags()
246 if (!ParseInt(arg, &entry->max_comp_streams)) { in ParseFsMgrFlags()
261 if (!ParseInt(arg, &val) || val < 4096 || (val & (val - 1)) != 0) { in ParseFsMgrFlags()
270 if (!ParseInt(arg, &val) || val < 4096 || (val & (val - 1)) != 0) { in ParseFsMgrFlags()
/system/vold/
Dvdc.cpp125 if (!android::base::ParseInt(args[2], &retry)) exit(EINVAL); in main()
143 if (!android::base::ParseInt(args[3], &count)) exit(EINVAL); in main()
149 if (!android::base::ParseInt(args[2], &retry)) exit(EINVAL); in main()
DProcess.cpp98 if (!android::base::ParseInt(proc_de->d_name, &pid)) continue; in KillProcessesWithOpenFiles()
/system/extras/simpleperf/simpleperf_app_runner/
Dsimpleperf_app_runner.cpp41 using android::base::ParseInt;
143 if (!ParseInt(args[i + 1], &fd) || fd < 3 || fcntl(fd, F_GETFD) == -1) { in CheckSimpleperfArguments()
/system/core/debuggerd/
Ddebuggerd.cpp78 if (!android::base::ParseInt(argv[argc - 1], &pid, 1, std::numeric_limits<pid_t>::max())) { in main()
Dcrash_dump.cpp241 if (!android::base::ParseInt(argv[1], &g_target_thread, 1, std::numeric_limits<pid_t>::max())) { in ParseArgs()
245 if (!android::base::ParseInt(argv[2], pseudothread_tid, 1, std::numeric_limits<pid_t>::max())) { in ParseArgs()
250 if (!android::base::ParseInt(argv[3], &dump_type_int, 0, 1)) { in ParseArgs()
/system/memory/libmemtrack/
Dmemtrack_test.cpp57 if (!::android::base::ParseInt(de.path().filename().string(), &pid)) { in main()
/system/gsid/
Dlibgsi.cpp133 return android::base::ParseInt(boot_key, attempts); in GetBootAttempts()
/system/core/adb/
Dsocket_spec.cpp91 if (android::base::ParseInt(&spec[4], &port_value)) { in parse_tcp_socket_spec()
134 if (!android::base::ParseInt(fragments[1], &port)) { in get_host_socket_spec_port()
362 if (!android::base::ParseInt(fragments[1], &port)) {
Dadb_utils.cpp257 if (!android::base::ParseInt(&source[4], &port) || port < 0) { in forward_targets_are_valid()
266 if (!android::base::ParseInt(&dest[4], &port) || port <= 0) { in forward_targets_are_valid()
/system/apex/apexd/
Dapex_database.cpp38 using android::base::ParseInt;
116 if (!ParseInt(split[1], &version)) { in parseMountPoint()
/system/core/libprocinfo/include/procinfo/
Dprocess.h85 if (!android::base::ParseInt(dent->d_name, &tid, 1, std::numeric_limits<pid_t>::max())) {
/system/vold/model/
DDisk.cpp254 if (!android::base::ParseInt(tmp, &manfid)) { in readMetadata()
348 if (!android::base::ParseInt(*it, &i, 1, maxMinors)) { in readPartitions()
357 if (!android::base::ParseInt("0x" + *it, &type)) { in readPartitions()
/system/core/fastboot/device/
Dtcp_client.cpp160 if (!android::base::ParseInt(buffer + 2, &version) || version < kProtocolVersion) { in ListenFastbootSocket()
/system/extras/simpleperf/
Denvironment.cpp229 if (!android::base::ParseInt(entry.c_str(), &pid, 0)) { in GetAllProcesses()
264 if (!android::base::ParseInt(s.c_str(), &tid, 0)) { in GetValidThreadsFromThreadString()
294 if (!android::base::ParseInt(s.c_str(), value)) { in ReadPerfEventAllowStatus()
483 if (!android::base::ParseInt(s.c_str(), &value)) { in CheckKernelSymbolAddresses()
/system/core/logd/
DReplayMessages.cpp39 using android::base::ParseInt;
300 if (!ParseInt(string_id, &result, 0, 7)) { in PrintLogs()

123