jaewonjoo / webp

Automatically exported from code.google.com/p/webp
0 stars 0 forks source link

Uninitialized warnings in lossless.c #116

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
1. Checkout git 0a49e3f3da3f1b931a53991bcc5e1fe14dccfd91
2. Compile

What is the expected output?
Clean compile

What do you see instead?
src/dsp/lossless.c: In function 'VP8LInverseTransform':
src/dsp/lossless.c:312:23: warning: 'packed_pixels' may be used uninitialized 
in this function [-Wuninitialized]
src/dsp/lossless.c:304:16: note: 'packed_pixels' was declared here
src/dsp/lossless.c:258:34: warning: 'm.red_to_blue_' may be used uninitialized 
in this function [-Wuninitialized]
src/dsp/lossless.c:275:17: note: 'm.red_to_blue_' was declared here
src/dsp/lossless.c:257:34: warning: 'm.green_to_blue_' may be used 
uninitialized in this function [-Wuninitialized]
src/dsp/lossless.c:275:17: note: 'm.green_to_blue_' was declared here
src/dsp/lossless.c:255:33: warning: 'm.green_to_red_' may be used uninitialized 
in this function [-Wuninitialized]
src/dsp/lossless.c:275:17: note: 'm.green_to_red_' was declared here

Fix
Attached patch initializes the variables

Original issue reported on code.google.com by pepijn.v...@gmail.com on 20 Apr 2012 at 9:08

Attachments:

GoogleCodeExporter commented 8 years ago
Spurious, but should be ok. This file still needs some work, there are type 
related issues in VS builds.

https://gerrit.chromium.org/gerrit/#change,20733

Original comment by jz...@google.com on 20 Apr 2012 at 7:37

GoogleCodeExporter commented 8 years ago
Merged. Thanks!

Original comment by jz...@google.com on 23 Apr 2012 at 6:46