Lines Matching refs:match_data
220 match_block *mb, pcre2_match_data *match_data, const char *s, ...) in display_frames() argument
232 ((char *)P - (char *)(match_data->heapframes))/frame_size); in display_frames()
235 for (i = 0, Q = match_data->heapframes; in display_frames()
595 PCRE2_SIZE frame_size, pcre2_match_data *match_data, match_block *mb) in match() argument
646 F = match_data->heapframes; in match()
647 frames_top = (heapframe *)((char *)F + match_data->heapframes_size); in match()
672 PCRE2_SIZE usedsize = (char *)N - (char *)(match_data->heapframes); in match()
674 if (match_data->heapframes_size >= PCRE2_SIZE_MAX / 2) in match()
676 if (match_data->heapframes_size == PCRE2_SIZE_MAX - 1) in match()
681 newsize = match_data->heapframes_size * 2; in match()
685 PCRE2_SIZE old_size = match_data->heapframes_size / 1024; in match()
691 int over_bytes = match_data->heapframes_size % 1024; in match()
693 newsize = match_data->heapframes_size + max_delta; in match()
701 new = match_data->memctl.malloc(newsize, match_data->memctl.memory_data); in match()
703 memcpy(new, match_data->heapframes, usedsize); in match()
708 match_data->memctl.free(match_data->heapframes, match_data->memctl.memory_data); in match()
709 match_data->heapframes = new; in match()
710 match_data->heapframes_size = newsize; in match()
769 Flast_group_offset = (char *)F - (char *)match_data->heapframes; in match()
817 N = (heapframe *)((char *)match_data->heapframes + offset); in match()
856 N = (heapframe *)((char *)match_data->heapframes + offset); in match()
931 match_data->ovector[0] = Fstart_match - mb->start_subject; in match()
932 match_data->ovector[1] = Feptr - mb->start_subject; in match()
936 i = 2 * ((top_bracket + 1 > match_data->oveccount)? in match()
937 match_data->oveccount : top_bracket + 1); in match()
938 memcpy(match_data->ovector + 2, Fovector, (i - 2) * sizeof(PCRE2_SIZE)); in match()
939 while (--i >= Foffset_top + 2) match_data->ovector[i] = PCRE2_UNSET; in match()
5443 N = (heapframe *)((char *)match_data->heapframes + offset); in match()
5924 N = (heapframe *)((char *)match_data->heapframes + Flast_group_offset); in match()
5971 N = (heapframe *)((char *)match_data->heapframes + offset); in match()
6531 PCRE2_SIZE start_offset, uint32_t options, pcre2_match_data *match_data, in pcre2_match() argument
6598 if (code == NULL || subject == NULL || match_data == NULL) in pcre2_match()
6678 if ((match_data->flags & PCRE2_MD_COPIED_SUBJECT) != 0) in pcre2_match()
6680 match_data->memctl.free((void *)match_data->subject, in pcre2_match()
6681 match_data->memctl.memory_data); in pcre2_match()
6682 match_data->flags &= ~PCRE2_MD_COPIED_SUBJECT; in pcre2_match()
6684 match_data->subject = NULL; in pcre2_match()
6688 match_data->startchar = 0; in pcre2_match()
6755 match_data->rc = PRIV(valid_utf)(start_match, in pcre2_match()
6756 length - (start_match - subject), &(match_data->startchar)); in pcre2_match()
6757 if (match_data->rc != 0) in pcre2_match()
6759 match_data->startchar += start_match - subject; in pcre2_match()
6760 return match_data->rc; in pcre2_match()
6770 match_data, mcontext); in pcre2_match()
6773 match_data->subject_length = length; in pcre2_match()
6777 match_data->subject = match_data->memctl.malloc(length, in pcre2_match()
6778 match_data->memctl.memory_data); in pcre2_match()
6779 if (match_data->subject == NULL) return PCRE2_ERROR_NOMEMORY; in pcre2_match()
6780 memcpy((void *)match_data->subject, subject, length); in pcre2_match()
6781 match_data->flags |= PCRE2_MD_COPIED_SUBJECT; in pcre2_match()
6891 match_data->rc = PRIV(valid_utf)(mb->check_subject, in pcre2_match()
6892 length - (mb->check_subject - subject), &(match_data->startchar)); in pcre2_match()
6894 if (match_data->rc == 0) break; /* Valid UTF string */ in pcre2_match()
6901 match_data->startchar += mb->check_subject - subject; in pcre2_match()
6902 if (!allow_invalid || match_data->rc > 0) return match_data->rc; in pcre2_match()
6903 end_subject = subject + match_data->startchar; in pcre2_match()
7065 if (match_data->heapframes_size < heapframes_size) in pcre2_match()
7067 match_data->memctl.free(match_data->heapframes, in pcre2_match()
7068 match_data->memctl.memory_data); in pcre2_match()
7069 match_data->heapframes = match_data->memctl.malloc(heapframes_size, in pcre2_match()
7070 match_data->memctl.memory_data); in pcre2_match()
7071 if (match_data->heapframes == NULL) in pcre2_match()
7073 match_data->heapframes_size = 0; in pcre2_match()
7076 match_data->heapframes_size = heapframes_size; in pcre2_match()
7082 memset((char *)(match_data->heapframes) + offsetof(heapframe, ovector), 0xff, in pcre2_match()
7515 match_data, mb); in pcre2_match()
7676 &(match_data->startchar)); in pcre2_match()
7692 mb->end_subject = end_subject = start_match + match_data->startchar; in pcre2_match()
7705 match_data->code = re; in pcre2_match()
7706 match_data->mark = mb->mark; in pcre2_match()
7707 match_data->matchedby = PCRE2_MATCHEDBY_INTERPRETER; in pcre2_match()
7716 match_data->rc = ((int)mb->end_offset_top >= 2 * match_data->oveccount)? in pcre2_match()
7718 match_data->subject_length = length; in pcre2_match()
7719 match_data->startchar = start_match - subject; in pcre2_match()
7720 match_data->leftchar = mb->start_used_ptr - subject; in pcre2_match()
7721 match_data->rightchar = ((mb->last_used_ptr > mb->end_match_ptr)? in pcre2_match()
7726 match_data->subject = match_data->memctl.malloc(length, in pcre2_match()
7727 match_data->memctl.memory_data); in pcre2_match()
7728 if (match_data->subject == NULL) return PCRE2_ERROR_NOMEMORY; in pcre2_match()
7729 memcpy((void *)match_data->subject, subject, length); in pcre2_match()
7730 match_data->flags |= PCRE2_MD_COPIED_SUBJECT; in pcre2_match()
7732 else match_data->subject = subject; in pcre2_match()
7734 return match_data->rc; in pcre2_match()
7741 match_data->mark = mb->nomatch_mark; in pcre2_match()
7745 if (rc != MATCH_NOMATCH && rc != PCRE2_ERROR_PARTIAL) match_data->rc = rc; in pcre2_match()
7754 match_data->subject = subject; in pcre2_match()
7755 match_data->subject_length = length; in pcre2_match()
7756 match_data->ovector[0] = match_partial - subject; in pcre2_match()
7757 match_data->ovector[1] = end_subject - subject; in pcre2_match()
7758 match_data->startchar = match_partial - subject; in pcre2_match()
7759 match_data->leftchar = start_partial - subject; in pcre2_match()
7760 match_data->rightchar = end_subject - subject; in pcre2_match()
7761 match_data->rc = PCRE2_ERROR_PARTIAL; in pcre2_match()
7766 else match_data->rc = PCRE2_ERROR_NOMATCH; in pcre2_match()
7768 return match_data->rc; in pcre2_match()