[FFmpeg-devel] [PATCH] Try to add some ways variables can be read in patcheck.

Michael Niedermayer michaelni
Fri Jun 11 00:05:08 CEST 2010


On Thu, Jun 10, 2010 at 05:56:38PM +0200, Benoit Fouet wrote:
> In if statement for instance, a variable is read when compared, or'd, and'd...
> ---
>  tools/patcheck |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/tools/patcheck b/tools/patcheck
> index a6923c4..0ebfd43 100755
> --- a/tools/patcheck
> +++ b/tools/patcheck
> @@ -112,7 +112,7 @@ for i in \
>      ; do
>      echo $i | grep '^NULL$' && continue
>      egrep $i' *(\+|-|\*|/|\||&|%|)=[^=]' $* >/dev/null || echo "possibly never written:"$i >> $TMP
> -    egrep '(=|\(|return).*'$i'[^=]*$'    $* >/dev/null || echo "possibly never read   :"$i >> $TMP
> +    egrep '(=|\(|return).*'$i'(( *(&*|\|*|==))|[^=])*$'    $* >/dev/null || echo "possibly never read   :"$i >> $TMP

doesnt [^=] already match most of these things (except ==)?

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Thouse who are best at talking, realize last or never when they are wrong.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20100611/9eee81dd/attachment.pgp>



More information about the ffmpeg-devel mailing list