Home
last modified time | relevance | path

Searched refs:cp (Results 1 – 25 of 34) sorted by relevance

12

/system/core/logd/
DLogKlog.cpp332 const char *cp = now.strptime(*buf, "[ %s.%q]"); in sniffTime() local
333 if (cp && (cp >= &(*buf)[len])) { in sniffTime()
334 cp = NULL; in sniffTime()
336 if (cp) { in sniffTime()
340 len -= cp - *buf; in sniffTime()
341 if (len && isspace(*cp)) { in sniffTime()
342 ++cp; in sniffTime()
345 *buf = cp; in sniffTime()
352 if (((b = strnstr(cp, len, suspendStr))) in sniffTime()
353 && ((size_t)((b += sizeof(suspendStr) - 1) - cp) < len)) { in sniffTime()
[all …]
DLogReader.cpp61 char *cp = strstr(buffer, _tail); in onDataAvailable() local
62 if (cp) { in onDataAvailable()
63 tail = atol(cp + sizeof(_tail) - 1); in onDataAvailable()
68 cp = strstr(buffer, _start); in onDataAvailable()
69 if (cp) { in onDataAvailable()
71 start.strptime(cp + sizeof(_start) - 1, "%s.%q"); in onDataAvailable()
76 cp = strstr(buffer, _timeout); in onDataAvailable()
77 if (cp) { in onDataAvailable()
78 timeout = atol(cp + sizeof(_timeout) - 1) * NS_PER_SEC + in onDataAvailable()
84 cp = strstr(buffer, _logIds); in onDataAvailable()
[all …]
DLogAudit.cpp95 char *cp; in logPrint() local
96 while ((cp = strstr(str, " "))) { in logPrint()
97 memmove(cp, cp + 1, strlen(cp + 1) + 1); in logPrint()
125 && ((cp = now.strptime(timeptr + sizeof(audit_str) - 1, "%s.%q"))) in logPrint()
126 && (*cp == ':')) { in logPrint()
128 memmove(timeptr + sizeof(audit_str) - 1 + 3, cp, strlen(cp) + 1); in logPrint()
147 cp = pidptr + sizeof(pid_str) - 1; in logPrint()
149 while (isdigit(*cp)) { in logPrint()
150 pid = (pid * 10) + (*cp - '0'); in logPrint()
151 ++cp; in logPrint()
[all …]
Dmain.cpp147 const char *cp = strcasestr(prop, flag); in check_flag() local
148 if (!cp) { in check_flag()
153 if ((cp != prop) && !strchr(sep, cp[-1])) { in check_flag()
156 cp += strlen(flag); in check_flag()
157 return !*cp || !!strchr(sep, *cp); in check_flag()
DLogBuffer.h129 int initPrune(const char *cp) { return mPrune.init(cp); } in initPrune() argument
/system/core/liblog/
Devent_tag_map.c229 const char* cp; in countMapLines() local
232 cp = (const char*) map->mapAddr; in countMapLines()
233 endp = cp + map->mapLen; in countMapLines()
237 while (cp < endp) { in countMapLines()
238 if (*cp == '\n') { in countMapLines()
241 if (isCharDigit(*cp)) { in countMapLines()
245 } else if (isCharWhitespace(*cp)) { in countMapLines()
254 cp++; in countMapLines()
266 char* cp; in parseMapLines() local
269 cp = (char*) map->mapAddr; in parseMapLines()
[all …]
Dlog_time.cpp54 char *cp; in strptime() local
55 for (char *f = cp = fmt; ; ++cp) { in strptime()
56 if (!*cp) { in strptime()
57 if (f != cp) { in strptime()
62 if (*cp != '%') { in strptime()
65 char *e = cp; in strptime()
69 *cp = '\0'; in strptime()
98 *cp = '\0'; in strptime()
117 f = cp = e; in strptime()
Dpmsg_writer.c195 const char *cp = buf + len; in strnrchr() local
196 while ((--cp > buf) && (*cp != c)); in strnrchr()
197 if (cp <= buf) { in strnrchr()
200 return cp; in strnrchr()
212 char *cp, *slash; in __android_log_pmsg_file_write() local
226 cp = strdup(filename); in __android_log_pmsg_file_write()
227 if (!cp) { in __android_log_pmsg_file_write()
241 tag = cp; in __android_log_pmsg_file_write()
242 slash = strrchr(cp, '/'); in __android_log_pmsg_file_write()
245 slash = strrchr(cp, '/'); in __android_log_pmsg_file_write()
[all …]
Dlogd_reader.c268 char *cp; in send_log_msg() local
287 cp = buf; in send_log_msg()
288 while ((ret = TEMP_FAILURE_RETRY(read(sock, cp, len))) > 0) { in send_log_msg()
296 cp += ret; in send_log_msg()
424 char *cp = buf; in logdGetStats() local
428 n = snprintf(cp, remaining, "getStatistics"); in logdGetStats()
431 cp += n; in logdGetStats()
434 n = snprintf(cp, remaining, " %d", logger->logId); in logdGetStats()
437 cp += n; in logdGetStats()
441 snprintf(cp, remaining, " pid=%u", logger_list->pid); in logdGetStats()
[all …]
Dpmsg_reader.c318 const char *prev = NULL, *last = NULL, *cp = prefix; in __android_log_pmsg_file_read() local
319 while ((cp = strpbrk(cp, "/:"))) { in __android_log_pmsg_file_read()
321 last = cp; in __android_log_pmsg_file_read()
322 cp = cp + 1; in __android_log_pmsg_file_read()
332 char *cp; in __android_log_pmsg_file_read() local
347 for (cp = msg + sizeof(prio); in __android_log_pmsg_file_read()
348 *cp && isprint(*cp) && !isspace(*cp) && --len; in __android_log_pmsg_file_read()
349 ++cp) { in __android_log_pmsg_file_read()
350 if (*cp == ':') { in __android_log_pmsg_file_read()
354 split = cp; in __android_log_pmsg_file_read()
[all …]
Dlogprint.c306 char *cp = getenv(tz); in android_log_formatFromString() local
307 if (cp) { in android_log_formatFromString()
308 cp = strdup(cp); in android_log_formatFromString()
322 if (cp) { in android_log_formatFromString()
323 setenv(tz, cp, 1); in android_log_formatFromString()
332 free(cp); in android_log_formatFromString()
1057 char *cp, *e = line; in convertMonotonic() local
1103 cp = strstr(e, " UTC"); in convertMonotonic()
1104 if (!cp || ((cp - e) < 29) || (cp[-10] != '.')) { in convertMonotonic()
1107 e = cp - 29; in convertMonotonic()
[all …]
/system/core/logd/tests/
Dlogd_test.cpp97 static char *find_benchmark_spam(char *cp) in find_benchmark_spam() argument
110 benchmark = strstr(cp, signature); in find_benchmark_spam()
114 cp = benchmark + sizeof(signature); in find_benchmark_spam()
115 while (isspace(*cp)) { in find_benchmark_spam()
116 ++cp; in find_benchmark_spam()
118 benchmark = cp; in find_benchmark_spam()
128 while (isdigit(*cp)) { in find_benchmark_spam()
129 ++cp; in find_benchmark_spam()
131 while (isspace(*cp)) { in find_benchmark_spam()
132 ++cp; in find_benchmark_spam()
[all …]
/system/extras/f2fs_utils/
Df2fs_sparseblock.c75 static void dbg_print_raw_ckpt_struct(struct f2fs_checkpoint *cp) in dbg_print_raw_ckpt_struct() argument
82 D_DISP_u64(cp, checkpoint_ver); in dbg_print_raw_ckpt_struct()
83 D_DISP_u64(cp, user_block_count); in dbg_print_raw_ckpt_struct()
84 D_DISP_u64(cp, valid_block_count); in dbg_print_raw_ckpt_struct()
85 D_DISP_u32(cp, rsvd_segment_count); in dbg_print_raw_ckpt_struct()
86 D_DISP_u32(cp, overprov_segment_count); in dbg_print_raw_ckpt_struct()
87 D_DISP_u32(cp, free_segment_count); in dbg_print_raw_ckpt_struct()
89 D_DISP_u32(cp, alloc_type[CURSEG_HOT_NODE]); in dbg_print_raw_ckpt_struct()
90 D_DISP_u32(cp, alloc_type[CURSEG_WARM_NODE]); in dbg_print_raw_ckpt_struct()
91 D_DISP_u32(cp, alloc_type[CURSEG_COLD_NODE]); in dbg_print_raw_ckpt_struct()
[all …]
/system/connectivity/shill/shims/
Dset_apn_helper.c59 char *cp; in main() local
113 cp = args; in main()
117 argname = cp; in main()
118 cp = strchr(cp, ','); in main()
119 if (cp == NULL) { in main()
125 *cp++ = '\0'; in main()
126 argvalue = cp; in main()
127 cp = strchr(cp, ','); in main()
128 if (cp == NULL) in main()
131 *cp++ = '\0'; in main()
/system/core/logcat/
Dlogcat.cpp434 static char *parseTime(log_time &t, const char *cp) { in parseTime() argument
436 char *ep = t.strptime(cp, "%m-%d %H:%M:%S.%q"); in parseTime()
440 ep = t.strptime(cp, "%Y-%m-%d %H:%M:%S.%q"); in parseTime()
444 return t.strptime(cp, "%s.%q"); in parseTime()
674 char *cp = parseTime(tail_time, optarg); in main() local
675 if (!cp) { in main()
679 if (*cp) { in main()
680 char c = *cp; in main()
681 *cp = '\0'; in main()
684 ret, optarg, c, cp + 1); in main()
[all …]
/system/core/lmkd/
Dlmkd.c429 static int zoneinfo_parse_protection(char *cp) { in zoneinfo_parse_protection() argument
434 for (cp = strtok_r(cp, "(), ", &save_ptr); cp; cp = strtok_r(NULL, "), ", &save_ptr)) { in zoneinfo_parse_protection()
435 zoneval = strtol(cp, &cp, 0); in zoneinfo_parse_protection()
444 char *cp = line; in zoneinfo_parse_line() local
448 cp = strtok_r(line, " ", &save_ptr); in zoneinfo_parse_line()
449 if (!cp) in zoneinfo_parse_line()
456 if (!strcmp(cp, "nr_free_pages")) in zoneinfo_parse_line()
458 else if (!strcmp(cp, "nr_file_pages")) in zoneinfo_parse_line()
460 else if (!strcmp(cp, "nr_shmem")) in zoneinfo_parse_line()
462 else if (!strcmp(cp, "high")) in zoneinfo_parse_line()
[all …]
/system/core/libutils/
DString8.cpp536 const char* cp; in getPathLeaf() local
539 cp = strrchr(buf, OS_PATH_SEPARATOR); in getPathLeaf()
540 if (cp == NULL) in getPathLeaf()
543 return String8(cp+1); in getPathLeaf()
548 const char* cp; in getPathDir() local
551 cp = strrchr(str, OS_PATH_SEPARATOR); in getPathDir()
552 if (cp == NULL) in getPathDir()
555 return String8(str, cp - str); in getPathDir()
560 const char* cp; in walkPath() local
564 cp = strchr(buf, OS_PATH_SEPARATOR); in walkPath()
[all …]
/system/core/crash_reporter/
Dwarn_collector_test.sh59 cp "${SRC}/warn_collector_test_reporter.sh" .
60 cp "${SRC}/TEST_WARNING" .
61 cp TEST_WARNING messages
/system/core/toolbox/upstream-netbsd/bin/dd/
Dargs.c363 struct conv *cp, tmp; in f_conv() local
367 if (!(cp = bsearch(&tmp, clist, in f_conv()
372 if (ddflags & cp->noset) { in f_conv()
377 ddflags |= cp->set; in f_conv()
378 if (cp->ctab) in f_conv()
379 ctab = cp->ctab; in f_conv()
/system/core/logcat/tests/
Dlogcat_test.cpp62 while (char *cp = strrchr(buffer, '\n')) { in TEST() local
63 *cp = '\0'; in TEST()
121 char *cp = buffer; in fgetLongTime() local
122 if (*cp != '[') { in fgetLongTime()
125 while (*++cp == ' ') { in fgetLongTime()
128 char *ep = cp; in fgetLongTime()
144 return cp; in fgetLongTime()
258 char *cp; in TEST() local
259 while ((cp = fgetLongTime(buffer, sizeof(buffer), fp))) { in TEST()
262 first_timestamp = strdup(cp); in TEST()
[all …]
/system/extras/ext4_utils/
Dtest_ext4fixup30 cp "$ORIG_FS_IMAGE" "$FIXED_FS_IMAGE"
51 cp "$ORIG_FS_IMAGE" "$NEW_FS_IMAGE"
/system/core/healthd/
Dhealthd.cpp214 char *cp; in uevent_event() local
225 cp = msg; in uevent_event()
227 while (*cp) { in uevent_event()
228 if (!strcmp(cp, "SUBSYSTEM=" POWER_SUPPLY_SUBSYSTEM)) { in uevent_event()
234 while (*cp++) in uevent_event()
/system/core/liblog/tests/
Dliblog_benchmark.cpp489 static unsigned long long caught_convert(char *cp) in caught_convert() argument
491 unsigned long long l = cp[0] & 0xFF; in caught_convert()
492 l |= (unsigned long long) (cp[1] & 0xFF) << 8; in caught_convert()
493 l |= (unsigned long long) (cp[2] & 0xFF) << 16; in caught_convert()
494 l |= (unsigned long long) (cp[3] & 0xFF) << 24; in caught_convert()
495 l |= (unsigned long long) (cp[4] & 0xFF) << 32; in caught_convert()
496 l |= (unsigned long long) (cp[5] & 0xFF) << 40; in caught_convert()
497 l |= (unsigned long long) (cp[6] & 0xFF) << 48; in caught_convert()
498 l |= (unsigned long long) (cp[7] & 0xFF) << 56; in caught_convert()
/system/bt/btif/co/
Dbta_av_co.c162 tBTA_AV_CO_CP cp; member
191 return bta_av_co_cb.cp.active; in bta_av_co_cp_is_active()
209 return bta_av_co_cb.cp.flag; in bta_av_co_cp_get_flag()
235 bta_av_co_cb.cp.flag = cp_flag; in bta_av_co_cp_set_flag()
556 bta_av_co_cb.cp.active = FALSE; in bta_av_audio_sink_getconfig()
695 bta_av_co_cb.cp.active = TRUE; in bta_av_co_audio_getconfig()
702 bta_av_co_cb.cp.active = FALSE; in bta_av_co_audio_getconfig()
827 else if ((num_protect == 1) && (!bta_av_co_cb.cp.active)) in bta_av_co_audio_setconfig()
1520 bta_av_co_cb.cp.active = TRUE; in bta_av_co_audio_codec_supported()
1525 bta_av_co_cb.cp.active = FALSE; in bta_av_co_audio_codec_supported()
/system/extras/tests/workloads/
Dpwrtest.sh176 cp $collectOutput $powerOutput
281 cp $powerOutput $displayPowerOutput
282 cp $airplanePowerOutput $airplaneDisplayPowerOutput

12