public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: allison.henderson@oracle.com
Cc: Allison Henderson <allison.henderson@oracle.com>,
	linux-xfs@vger.kernel.org
Subject: [bug report] xfs: Add delay ready attr remove routines
Date: Thu, 17 Jun 2021 17:22:59 +0300	[thread overview]
Message-ID: <YMtaw9vsW69xGseU@mwanda> (raw)

Hello Allison Henderson,

The patch 2b74b03c13c4: "xfs: Add delay ready attr remove routines"
from Apr 26, 2021, leads to the following static checker warning:

	fs/xfs/libxfs/xfs_attr.c:1481 xfs_attr_remove_iter()
	error: uninitialized symbol 'error'.

fs/xfs/libxfs/xfs_attr.c
  1469                          return -EAGAIN;
  1470                  }
  1471  
  1472                  /* fallthrough */
  1473          case XFS_DAS_RM_SHRINK:
  1474                  /*
  1475                   * If the result is small enough, push it all into the inode.
  1476                   * This is our final state so it's safe to return a dirty
  1477                   * transaction.
  1478                   */
  1479                  if (xfs_attr_is_leaf(dp))
  1480                          error = xfs_attr_node_shrink(args, state);
  1481                  ASSERT(error != -EAGAIN);

Not initialized on the else path.  It should be zero right?

  1482                  break;
  1483          default:
  1484                  ASSERT(0);
  1485                  error = -EINVAL;
  1486                  goto out;
  1487          }
  1488  out:
  1489          if (state)
  1490                  xfs_da_state_free(state);
  1491          return error;
                ^^^^^^^^^^^^
returned here.

  1492  }

regards,
dan carpenter

             reply	other threads:[~2021-06-17 14:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-17 14:22 Dan Carpenter [this message]
2021-06-22  7:59 ` [bug report] xfs: Add delay ready attr remove routines Allison Henderson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YMtaw9vsW69xGseU@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=allison.henderson@oracle.com \
    --cc=linux-xfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox