Skip to content

Commit

Permalink
btrfs: send: remove BUG from process_all_refs
Browse files Browse the repository at this point in the history
There are only 2 static callers, the BUG would normally be never
reached, but let's be nice.

Signed-off-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Josef Bacik <jbacik@fb.com>
  • Loading branch information
David Sterba authored and Josef Bacik committed Mar 10, 2014
1 parent 1f5a7ff commit 4d1a63b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion fs/btrfs/send.c
Original file line number Diff line number Diff line change
Expand Up @@ -3606,7 +3606,10 @@ static int process_all_refs(struct send_ctx *sctx,
root = sctx->parent_root;
cb = __record_deleted_ref;
} else {
BUG();
btrfs_err(sctx->send_root->fs_info,
"Wrong command %d in process_all_refs", cmd);
ret = -EINVAL;
goto out;
}

key.objectid = sctx->cmp_key->objectid;
Expand Down

0 comments on commit 4d1a63b

Please sign in to comment.