[bug report] xfs: Add delay ready attr remove routines

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux