freetype-devel
[Top][All Lists]
Advanced

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

Re: [ft-devel] WIP PATCH: clang static analyzer and warning fixes


From: Alexei Podtelezhnikov
Subject: Re: [ft-devel] WIP PATCH: clang static analyzer and warning fixes
Date: Tue, 18 Mar 2014 17:07:08 -0400




On Tue, Mar 18, 2014 at 2:37 AM, Werner LEMBERG <address@hidden> wrote:

> The patch 0004 is false positive.  The variable 'hit' is set to zero
> when entering the loop so 'p_last' and 'p_first' are assigned almost
> immediately.

Thanks for the analysis.  However, initializing doesn't hurt, and
pacifying one of the most used compilers is probably a good thing.


It is ugly. First we initialize to 0, then twenty lines down we reassign both variables to -1. It looks like we do not know what we are doing. If the -1 is of any special fallback meaning, I would use it in the initialization and drop lines 575 and 573. Any objection?

reply via email to

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