xfs: fix error initialization

Eric Sandeen reported a gcc complaint about uninitialized error
variables, so fix that.

Signed-off-by: Darrick J. Wong <[email protected]>
Reported-by: Eric Sandeen <[email protected]>
Reviewed-by: Dave Chinner <[email protected]>
Signed-off-by: Dave Chinner <[email protected]>
This commit is contained in:
Darrick J. Wong 2016-10-10 16:49:18 +11:00 • committed by Dave Chinner
commit 9780643cde

View file

@ -1437,7 +1437,7 @@ xfs_reflink_dirty_extents(
xfs_off_t flen;
struct xfs_bmbt_irec map[2];
int nmaps;
int error;
int error = 0;
while (end - fbno > 0) {
nmaps = 1;