Re: [PATCH] grep: print the pcre2_jit_on value
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- Jul 23, 2019, 19:19 UTC
- Message-ID
- <nycvar.QRO.7.76.6.1907232118460.21907@tvgsbejvaqbjf.bet>
- In-Reply-To
- <20190722181923.21572-1-dev+git@drbeat.li>
Hi Beat,
On Mon, 22 Jul 2019, Beat Bolli wrote:
Show 20 quoted lines
> When pcre2_jit_on is neither 1 nor 0, the BUG() call printed the value
> of pcre1_jit_on.
>
> Print the value of pcre2_jit_on instead.
>
> Signed-off-by: Beat Bolli <dev+git@drbeat.li>
> ---
> grep.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/grep.c b/grep.c
> index f7c3a5803e..cd952ef5d3 100644
> --- a/grep.c
> +++ b/grep.c
> @@ -559,7 +559,7 @@ static void compile_pcre2_pattern(struct grep_pat *p, const struct grep_opt *opt
> pcre2_jit_stack_assign(p->pcre2_match_context, NULL, p->pcre2_jit_stack);
> } else if (p->pcre2_jit_on != 0) {
> BUG("The pcre2_jit_on variable should be 0 or 1, not %d",
> - p->pcre1_jit_on);
> + p->pcre2_jit_on);Seems obviously good.
Maybe while you're in the vicinity, you can add that information to the `--debug` output?
Thanks, Dscho
Show 7 quoted lines
> } > } > > -- > 2.21.0.1020.gf2820cf01a > >