]> git.baikalelectronics.ru Git - kernel.git/commit
nbd: fix return value in error handling path
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Mon, 12 Feb 2018 17:14:55 +0000 (11:14 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 27 Feb 2018 22:51:37 +0000 (15:51 -0700)
commit48eeb50402c4a63c3f4a645a9bd589acb47567b0
tree57ae9ad76e537253eb4a530d0721ccfe40cbdd1c
parent4e9dc5391a2a5677e86722ccae186e7e6411564e
nbd: fix return value in error handling path

It seems that the proper value to return in this particular case is the
one contained into variable new_index instead of ret.

Addresses-Coverity-ID: 1465148 ("Copy-paste error")
Fixes: 2178b90c44fa ("nbd: add a basic netlink interface")
Reviewed-by: Omar Sandoval <osandov@fb.com>
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/nbd.c