bug-gnulib
[Top][All Lists]
Advanced

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

Re: [PATCH v2 02/10] gnulib/regexec: Fix possible null-dereference


From: Robbie Harwood
Subject: Re: [PATCH v2 02/10] gnulib/regexec: Fix possible null-dereference
Date: Thu, 09 Dec 2021 12:22:54 -0500

Paul Eggert <eggert@cs.ucla.edu> writes:

> On 12/7/21 09:38, Robbie Harwood wrote:
>
>> My*guess*  is that Coverity has noticed that `mctx->state_log` is
>> checked against NULL in many other places in that file, and was unable
>> to prove to itself that it couldn't be NULL there too.  If that's the
>> case, a DEBUG_ASSERT would presumably do the trick better.
>
> Yes, I can see why Coverity can't deduce the code is safe.
>
> I installed the attached patch into Gnulib; it adds a DEBUG_ASSERT which 
> should be a reasonable prophylactic even if we don't use Coverity. I 
> hope this also suffices to pacify Coverity.

Thanks!

Be well,
--Robbie

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]