Re: [PATCH v5 05/19] grep: remove redundant `regflags &= ~REG_EXTENDED` assignments

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ævar Arnfjörð Bjarmason  <avarab@xxxxxxxxx> writes:

>>> @@ -417,7 +415,6 @@ static void compile_fixed_regexp(struct grep_pat *p, struct grep_opt *opt)
>>>       int regflags;
>>>
>>>       basic_regex_quote_buf(&sb, p->pattern);
>>> -     regflags = opt->regflags & ~REG_EXTENDED;
>>>       if (opt->ignore_case)
>>>               regflags |= REG_ICASE;
>>>       err = regcomp(&p->regexp, sb.buf, regflags);
>>
>> This hunk is wrong.  Now the use of regflags we see in the post
>> context is mixing ICASE bit into an uninitialized garbage on the
>> stack.
>
> Oops, sorry about that. Here's a fixed version. Just sending a v5 for
> this, not the entire rest of the series. If you'd like to grab it in
> .git form it's github.com/avar/git:avar/pcre2-5, this is the only
> change from v4.

Thanks; I think I already queued an equivalent SQUASH??? patch
queued at the tip before merging it to 'pu', so it hopefully would
be the matter of running "rebase -i" and not making mistake when
instructing the command where to squash it in ;-)



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]