Lines Matching refs:text

395 	char *text = text_origin;  in print_match_error()  local
396 int middle = max_line_len(text) + 2; in print_match_error()
399 while (*pattern || *text) { in print_match_error()
405 while (*text && *text != '\n') { in print_match_error()
406 if (text == text_pos) in print_match_error()
408 fputc(*text, out); in print_match_error()
409 ++text; in print_match_error()
412 if (text == text_pos) in print_match_error()
437 if (*text) in print_match_error()
438 ++text; in print_match_error()
490 static bool match_pattern(struct btf *btf, char *pattern, char *text, char *reg_map[][2]) in match_pattern() argument
493 char *text_origin = text; in match_pattern()
498 if (!*text) in match_pattern()
503 if (!isspace(*text) && text != text_origin && isalnum(text[-1])) in match_pattern()
506 text = skip_space(text); in match_pattern()
518 text_next = match_str(text, reg_map[i][1]); in match_pattern()
523 text = text_next; in match_pattern()
569 text_next = match_number(text, acc_offset); in match_pattern()
577 text = text_next; in match_pattern()
591 text_next = match_number(text, field_offset); in match_pattern()
599 text = text_next; in match_pattern()
608 if (strncmp(pattern, text, matches[0].rm_eo) != 0) in match_pattern()
612 text += matches[0].rm_eo; in match_pattern()
617 if (*pattern != *text) in match_pattern()
621 ++text; in match_pattern()
628 print_match_error(stdout, pattern_origin, text_origin, pattern, text); in match_pattern()
650 char *text = NULL; in match_program() local
653 text = calloc(MAX_PROG_TEXT_SZ, 1); in match_program()
654 if (!text) { in match_program()
661 opts.log_buf = text; in match_program()
670 errno, strerror(errno), text); in match_program()
674 memset(text, 0, MAX_PROG_TEXT_SZ); in match_program()
682 prog_out = fmemopen(text, MAX_PROG_TEXT_SZ - 1, "w"); in match_program()
695 ASSERT_TRUE(match_pattern(btf, pattern, text, reg_map), in match_program()
702 free(text); in match_program()