Home
last modified time | relevance | path

Searched refs:line (Results 1 – 25 of 155) sorted by relevance

1234567

/system/extras/memory_replay/tests/
DLineBufferTest.cpp49 char* line; in TEST_F() local
51 ASSERT_TRUE(line_buf.GetLine(&line, &line_len)); in TEST_F()
52 ASSERT_STREQ("Single line with newline.", line); in TEST_F()
55 ASSERT_FALSE(line_buf.GetLine(&line, &line_len)); in TEST_F()
68 char* line; in TEST_F() local
70 ASSERT_TRUE(line_buf.GetLine(&line, &line_len)); in TEST_F()
71 ASSERT_STREQ("Single line with no newline.", line); in TEST_F()
74 ASSERT_FALSE(line_buf.GetLine(&line, &line_len)); in TEST_F()
89 char* line; in TEST_F() local
91 ASSERT_TRUE(line_buf.GetLine(&line, &line_len)); in TEST_F()
[all …]
DActionTest.cpp26 const char* line = "1024"; in TEST() local
27 Action* action = Action::CreateAction(0x1234, "malloc", line, memory); in TEST()
41 const char* line = ""; in TEST() local
42 Action* action = Action::CreateAction(0x1234, "malloc", line, memory); in TEST()
48 const char* line = ""; in TEST() local
49 Action* action = Action::CreateAction(0x1234, "free", line, memory); in TEST()
61 const char* line = "100 10"; in TEST() local
62 Action* action = Action::CreateAction(0x1234, "calloc", line, memory); in TEST()
76 const char* line = ""; in TEST() local
77 Action* action = Action::CreateAction(0, "free", line, memory); in TEST()
[all …]
/system/bt/btif/src/
Dbtif_sock_util.c171 char *line; in dump_bin() local
178 line = line_buff; in dump_bin()
179 *line++ = ' '; in dump_bin()
180 *line++ = ' '; in dump_bin()
181 *line++ = ' '; in dump_bin()
182 *line++ = ' '; in dump_bin()
183 *line++ = ' '; in dump_bin()
184 *line++ = ' '; in dump_bin()
187 byte2hex((const char*)&j, &line); in dump_bin()
188 *line++ = ' '; in dump_bin()
[all …]
/system/extras/tests/sdcard/
Dplot_sdcard.py50 def __init__(self, line): argument
52 'duration ([0-9.]+). Samples: ([0-9]+)'), line)
97 def Parse(self, line): argument
98 if line.startswith('# Kernel:'):
99 self.kernel = re.search('Linux version ([0-9.]+-[^ ]+)', line).group(1)
100 elif line.startswith('# Command:'):
101 self.command_line = re.search('# Command: [/\w_]+ (.*)', line).group(1)
105 elif line.startswith('# Iterations'):
106 self.iterations = int(re.search('# Iterations: ([0-9]+)', line).group(1))
107 elif line.startswith('# Fadvise'):
[all …]
/system/core/healthd/
DAnimationParser.cpp40 bool remove_prefix(const std::string& line, const char* prefix, const char** rest) { in remove_prefix() argument
41 const char* str = line.c_str(); in remove_prefix()
91 for (const auto& line : base::Split(content, "\n")) { in parse_animation_desc() local
95 if (can_ignore_line(line.c_str())) { in parse_animation_desc()
97 } else if (remove_prefix(line, animation_prefix, &rest)) { in parse_animation_desc()
102 LOGE("Bad animation format: %s\n", line.c_str()); in parse_animation_desc()
107 } else if (remove_prefix(line, fail_prefix, &rest)) { in parse_animation_desc()
109 } else if (remove_prefix(line, clock_prefix, &rest)) { in parse_animation_desc()
111 LOGE("Bad clock_display format: %s\n", line.c_str()); in parse_animation_desc()
114 } else if (remove_prefix(line, percent_prefix, &rest)) { in parse_animation_desc()
[all …]
/system/extras/perfprofd/quipper/base/
Dlogging.cc60 LogMessage::LogMessage(const char* file, int line, LogSeverity severity) in LogMessage() argument
61 : severity_(severity), file_(file), line_(line) { in LogMessage()
62 Init(file, line); in LogMessage()
65 LogMessage::LogMessage(const char* file, int line, std::string* result) in LogMessage() argument
66 : severity_(LOG_FATAL), file_(file), line_(line) { in LogMessage()
67 Init(file, line); in LogMessage()
72 LogMessage::LogMessage(const char* file, int line, LogSeverity severity, in LogMessage() argument
74 : severity_(severity), file_(file), line_(line) { in LogMessage()
75 Init(file, line); in LogMessage()
/system/netd/server/
DDumpWriter.cpp48 void DumpWriter::println(const std::string& line) { in println() argument
49 if (!line.empty()) { in println()
53 write(mFd, line.c_str(), line.size()); in println()
59 std::string line; in println() local
62 StringAppendV(&line, fmt, ap); in println()
64 println(line); in println()
/system/tools/aidl/
Daidl_language.cpp40 AidlType::AidlType(const std::string& name, unsigned line, in AidlType() argument
43 line_(line), in AidlType()
52 std::string name, unsigned line) in AidlArgument() argument
57 line_(line) {} in AidlArgument()
59 AidlArgument::AidlArgument(AidlType* type, std::string name, unsigned line) in AidlArgument() argument
64 line_(line) {} in AidlArgument()
96 unsigned line, const std::string& comments, int id) in AidlMethod() argument
101 line_(line), in AidlMethod()
114 unsigned line, const std::string& comments) in AidlMethod() argument
115 : AidlMethod(oneway, type, name, args, line, comments, 0) { in AidlMethod()
[all …]
Daidl_language_y.yy95 { ps->AddImport($2, @1.begin.line); };
117 @2.begin.line, $2->GetText().c_str());
123 $$ = new AidlParcelable($2, @2.begin.line, ps->Package());
126 $$ = new AidlParcelable($2, @2.begin.line, ps->Package(), $4->GetText());
130 ps->FileName().c_str(), @1.begin.line);
135 ps->FileName().c_str(), @2.begin.line, $2->GetText().c_str());
141 $$ = new AidlInterface($2->GetText(), @2.begin.line, $1->GetComments(),
147 $$ = new AidlInterface($3->GetText(), @3.begin.line, $1->GetComments(),
155 ps->FileName().c_str(), @2.begin.line, $2->GetText().c_str());
162 ps->FileName().c_str(), @2.begin.line, $2->GetText().c_str());
[all …]
Dline_reader.cpp42 bool ReadLine(string* line) override { in ReadLine() argument
46 line->clear(); in ReadLine()
47 std::getline(input_stream_, *line); in ReadLine()
62 bool ReadLine(string* line) override { in ReadLine() argument
66 line->clear(); in ReadLine()
67 std::getline(input_stream_, *line); in ReadLine()
/system/extras/tests/lib/testUtil/
DtestUtil.c148 char line[MAXSTR]; in testPrint() local
152 vsnprintf(line, sizeof(line), fmt, args); in testPrint()
154 ALOG(LOG_ERROR, logCatTag, "%s", line); in testPrint()
156 ALOG(LOG_INFO, logCatTag, "%s", line); in testPrint()
324 char line[MAXSTR]; in testXDump() local
327 char *linep = line; in testXDump()
331 if (linep != line) { in testXDump()
332 testPrintE("%s", line); in testXDump()
334 linep = line; in testXDump()
335 rv = snprintf(linep, ALEN(line) - (linep - line), in testXDump()
[all …]
/system/core/adb/
Dbugreport.cpp78 for (const auto& line : invalid_lines_) { in Done() local
79 fprintf(stderr, "\t%s\n", line.c_str()); in Done()
128 void ProcessLine(const std::string& line) { in ProcessLine() argument
129 if (line.empty()) return; in ProcessLine()
131 if (android::base::StartsWith(line, BUGZ_BEGIN_PREFIX)) { in ProcessLine()
132 SetSrcFile(&line[strlen(BUGZ_BEGIN_PREFIX)]); in ProcessLine()
133 } else if (android::base::StartsWith(line, BUGZ_OK_PREFIX)) { in ProcessLine()
134 SetSrcFile(&line[strlen(BUGZ_OK_PREFIX)]); in ProcessLine()
135 } else if (android::base::StartsWith(line, BUGZ_FAIL_PREFIX)) { in ProcessLine()
136 const char* error_message = &line[strlen(BUGZ_FAIL_PREFIX)]; in ProcessLine()
[all …]
/system/extras/memory_replay/
DAction.cpp59 MallocAction(uintptr_t key_pointer, const char* line) : AllocAction(key_pointer) { in MallocAction() argument
60 if (sscanf(line, "%zu", &size_) != 1) { in MallocAction()
79 CallocAction(uintptr_t key_pointer, const char* line) : AllocAction(key_pointer) { in CallocAction() argument
80 if (sscanf(line, "%zu %zu", &n_elements_, &size_) != 2) { in CallocAction()
102 ReallocAction(uintptr_t key_pointer, const char* line) : AllocAction(key_pointer) { in ReallocAction() argument
103 if (sscanf(line, "%" SCNxPTR " %zu", &old_pointer_, &size_) != 2) { in ReallocAction()
132 MemalignAction(uintptr_t key_pointer, const char* line) : AllocAction(key_pointer) { in MemalignAction() argument
133 if (sscanf(line, "%zu %zu", &align_, &size_) != 2) { in MemalignAction()
180 const char* line, void* action_memory) { in CreateAction() argument
183 action = new (action_memory) MallocAction(key_pointer, line); in CreateAction()
[all …]
Dmain.cpp41 char* line; in GetMaxAllocs() local
44 while (line_buf.GetLine(&line, &line_len)) { in GetMaxAllocs()
45 char* word = reinterpret_cast<char*>(memchr(line, ':', line_len)); in GetMaxAllocs()
82 char* line; in ProcessDump() local
85 while (line_buf.GetLine(&line, &line_len)) { in ProcessDump()
95 if (sscanf(line, "%d: %s %" SCNxPTR " %n", &tid, type, &key_pointer, &line_pos) != 3) { in ProcessDump()
96 err(1, "Unparseable line found: %s\n", line); in ProcessDump()
112 Action* action = thread->CreateAction(key_pointer, type, line + line_pos); in ProcessDump()
114 err(1, "Cannot create action from line: %s\n", line); in ProcessDump()
DNativeInfo.cpp36 char* line; in GetNativeInfo() local
41 while (line_buf.GetLine(&line, &line_len)) { in GetNativeInfo()
45 if (sscanf(line, "%" SCNxPTR "-%" SCNxPTR " %*4s %*x %*x:%*x %*d %n", in GetNativeInfo()
47 if (strcmp(line + name_pos, "[anon:libc_malloc]") == 0 || in GetNativeInfo()
48 strcmp(line + name_pos, "[heap]") == 0) { in GetNativeInfo()
54 } else if (native_map && sscanf(line, "Pss: %zu", &native_pss_kB) == 1) { in GetNativeInfo()
DLineBuffer.cpp26 bool LineBuffer::GetLine(char** line, size_t* line_len) { in GetLine() argument
32 *line = buffer_ + start_; in GetLine()
34 bytes_ -= newline - *line + 1; in GetLine()
35 *line_len = newline - *line; in GetLine()
49 *line = buffer_ + start_; in GetLine()
/system/core/logd/
DLogCommand.cpp102 char *line = NULL; in clientHasLogCredentials() local
104 while (getline(&line, &len, file) > 0) { in clientHasLogCredentials()
109 if (strncmp(groups_string, line, sizeof(groups_string) - 1) == 0) { in clientHasLogCredentials()
110 if (groupIsLog(line + sizeof(groups_string) - 1)) { in clientHasLogCredentials()
113 } else if (strncmp(uid_string, line, sizeof(uid_string) - 1) == 0) { in clientHasLogCredentials()
116 sscanf(line + sizeof(uid_string) - 1, "%u\t%u\t%u\t%u", in clientHasLogCredentials()
126 } else if (strncmp(gid_string, line, sizeof(gid_string) - 1) == 0) { in clientHasLogCredentials()
129 sscanf(line + sizeof(gid_string) - 1, "%u\t%u\t%u\t%u", in clientHasLogCredentials()
141 free(line); in clientHasLogCredentials()
/system/extras/simpleperf/
Dreport.py92 for line in lines:
93 if not line:
95 if not line[0].isspace():
96 cur_report_item = ReportItem(line)
101 for i in range(len(line)):
102 if line[i] == '|':
106 if not line.strip('| \t'):
108 if line.find('-') == -1:
109 line = line.strip('| \t')
110 function_name = line
[all …]
/system/connectivity/shill/
Dfile_reader_unittest.cc36 string line; in VerifyReadLines() local
37 EXPECT_FALSE(reader_.ReadLine(&line)); in VerifyReadLines()
40 EXPECT_TRUE(reader_.ReadLine(&line)); in VerifyReadLines()
41 EXPECT_EQ(lines[i], line); in VerifyReadLines()
43 EXPECT_FALSE(reader_.ReadLine(&line)); in VerifyReadLines()
45 EXPECT_FALSE(reader_.ReadLine(&line)); in VerifyReadLines()
63 string line; in TEST_F() local
64 EXPECT_FALSE(reader_.ReadLine(&line)); in TEST_F()
/system/tools/aidl/tests/
Daidl_test_sentinel_searcher.cpp43 string line; in ReadLines() local
44 while (getline(watched_file, line)) { in ReadLines()
45 lines->push_back(line); in ReadLines()
52 for (const auto& line : lines) { in HasSentinel() local
53 if (line.find(sentinel) != string::npos) { in HasSentinel()
107 for (const auto& line : lines) { in main() local
108 cout << " " << line << endl; in main()
/system/extras/showmap/
Dshowmap.cpp43 static int parse_header(const char* line, const mapinfo* prev, mapinfo** mi) { in parse_header() argument
50 if (sscanf(line, "%lx-%lx %*s %*x %*x:%*x %*d%n", &start, &end, &name_pos) != 2) { in parse_header()
55 while (isspace(line[name_pos])) { in parse_header()
59 if (line[name_pos]) { in parse_header()
60 strlcpy(name, line + name_pos, sizeof(name)); in parse_header()
90 static int parse_field(mapinfo* mi, const char* line) { in parse_field() argument
94 if (sscanf(line, "%63s %n", field, &len) == 1 in parse_field()
97 if (sscanf(line + len, "%d kB", &size) == 1) { in parse_field()
173 char line[1024]; in load_maps() local
185 while (fgets(line, sizeof(line), fp) != 0) { in load_maps()
[all …]
/system/core/libmemunreachable/
DLineBuffer.cpp29 bool LineBuffer::GetLine(char** line, size_t* line_len) { in GetLine() argument
35 *line = buffer_ + start_; in GetLine()
37 bytes_ -= newline - *line + 1; in GetLine()
38 *line_len = newline - *line; in GetLine()
52 *line = buffer_ + start_; in GetLine()
/system/core/libbacktrace/
DBacktraceMap.cpp48 bool BacktraceMap::ParseLine(const char* line, backtrace_map_t* map) { argument
59 if (sscanf(line, "%*21c %lx-%lx [%*13c] %3c/%*3c SM=%*3c %n",
66 if (sscanf(line, "%lx-%lx %4s %*x %*x:%*x %*d %n",
85 map->name = line+name_pos;
102 char line[1024]; local
117 while(fgets(line, sizeof(line), fp)) {
119 if (ParseLine(line, &map)) {
/system/extras/perfprofd/
Dconfigreader.cc238 static bool isblank(const std::string &line) in isblank() argument
240 for (std::string::const_iterator it = line.begin(); it != line.end(); ++it) in isblank()
257 std::string line; in readFile() local
259 std::getline(ss,line,'\n'); in readFile()
264 if (line[0] == '#') { in readFile()
269 if (isblank(line.c_str())) { in readFile()
274 auto efound = line.find('='); in readFile()
280 std::string key(line.substr(0, efound)); in readFile()
281 std::string value(line.substr(efound+1, std::string::npos)); in readFile()
/system/core/debuggerd/
Dtombstone.cpp244 std::string line; in dump_stack_segment() local
246 line = " "; in dump_stack_segment()
249 line += android::base::StringPrintf("#%02d ", label); in dump_stack_segment()
251 line += " "; in dump_stack_segment()
253 line += android::base::StringPrintf("%" PRIPTR " %" PRIPTR, *sp, stack_data[i]); in dump_stack_segment()
258 line += " " + map.name; in dump_stack_segment()
262 line += " (" + func_name; in dump_stack_segment()
264 line += android::base::StringPrintf("+%" PRIuPTR, offset); in dump_stack_segment()
266 line += ')'; in dump_stack_segment()
269 _LOG(log, logtype::STACK, "%s\n", line.c_str()); in dump_stack_segment()
[all …]

1234567