gif: avoid (wrong) uninitialized warning

My guess is that GCC reports an warning because of the default case.

I don't think we support yet __builtin_unreachable on Linux
Nevertheless it will still be an issue in non-release build
This commit is contained in:
Gregory Hainaut 2017-04-23 19:16:15 +02:00
parent dc00af8829
commit 3a04e3d003
1 changed files with 1 additions and 0 deletions

View File

@ -79,6 +79,7 @@ struct Gif_Tag {
hasAD = false; hasAD = false;
nRegIdx = 0; nRegIdx = 0;
isValid = 1; isValid = 1;
len = 0; // avoid uninitialized compiler warning
switch(tag.FLG) { switch(tag.FLG) {
case GIF_FLG_PACKED: case GIF_FLG_PACKED:
nRegs = ((tag.NREG-1)&0xf) + 1; nRegs = ((tag.NREG-1)&0xf) + 1;