Print this page
11506 smatch resync


   9 {
  10         struct ture *aa;
  11 
  12         b = 0;
  13         if (a)
  14                 goto x;
  15         aa = returns_nonnull();
  16         b = 1;
  17 x:
  18         if (b)
  19                 aa->a = 1;
  20         aa->a = 1;
  21         return;
  22 }
  23 /*
  24  * check-name: Smatch implied #1
  25  * check-command: smatch --spammy sm_implied.c
  26  *
  27  * check-output-start
  28 sm_implied.c:20 func() error: potentially dereferencing uninitialized 'aa'.

  29  * check-output-end
  30  */


   9 {
  10         struct ture *aa;
  11 
  12         b = 0;
  13         if (a)
  14                 goto x;
  15         aa = returns_nonnull();
  16         b = 1;
  17 x:
  18         if (b)
  19                 aa->a = 1;
  20         aa->a = 1;
  21         return;
  22 }
  23 /*
  24  * check-name: Smatch implied #1
  25  * check-command: smatch --spammy sm_implied.c
  26  *
  27  * check-output-start
  28 sm_implied.c:20 func() error: potentially dereferencing uninitialized 'aa'.
  29 sm_implied.c:20 func() error: potentially dereferencing uninitialized 'aa'.
  30  * check-output-end
  31  */