]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
dccp: fix warning in net/dccp/options.c
authorIngo Molnar <mingo@elte.hu>
Wed, 26 Nov 2008 00:57:30 +0000 (16:57 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 26 Nov 2008 00:57:30 +0000 (16:57 -0800)
commit3ed7cc0f8b29da4304825a7bcef25fc83f84c1ae
treeee7dcfc216faa1668b763b25af55ad569e920f28
parentb71e839f9a33abf8634b1eea4875bc8057fe39e2
dccp: fix warning in net/dccp/options.c

this warning:

  net/dccp/options.c: In function ‘dccp_parse_options’:
  net/dccp/options.c:67: warning: ‘value’ may be used uninitialized in this function

is a bogus GCC warning. The compiler does not recognize the relation
between "value" and "mandatory" variables: the code flow can ever reach
the "out_invalid_option:" label if 'mandatory' is set to 1, and when
'mandatory' is non-zero, we'll always have 'value' initialized.

Help out the compiler by annotating the variable.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/dccp/options.c