Skip to content

Commit

Permalink
btrfs: send: remove redundant assignments to variable ret
Browse files Browse the repository at this point in the history
The variable ret is being initialized to zero and also later re-assigned
to zero. In both cases the assignment is redundant since the value is
never read after the assignment and hence they can be removed.

Signed-off-by: Colin Ian King <[email protected]>
Reviewed-by: David Sterba <[email protected]>
Signed-off-by: David Sterba <[email protected]>
  • Loading branch information
ColinIanKing authored and kdave committed Nov 26, 2024
1 parent bc499d3 commit 1b93558
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions fs/btrfs/send.c
Original file line number Diff line number Diff line change
Expand Up @@ -7253,7 +7253,7 @@ static int changed_cb(struct btrfs_path *left_path,
enum btrfs_compare_tree_result result,
struct send_ctx *sctx)
{
int ret = 0;
int ret;

/*
* We can not hold the commit root semaphore here. This is because in
Expand Down Expand Up @@ -7313,7 +7313,6 @@ static int changed_cb(struct btrfs_path *left_path,
return 0;
}
result = BTRFS_COMPARE_TREE_CHANGED;
ret = 0;
}

sctx->left_path = left_path;
Expand Down

0 comments on commit 1b93558

Please sign in to comment.