Commit e1984086 authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Jason Gunthorpe

RDMA/rtrs: client: Fix function return on success

Remove the if-statement and return the value contained in _err_,
unconditionally.

Link: https://lore.kernel.org/r/20200519163612.GA6043@embeddedor
Addresses-Coverity-ID: 1493753 ("Identical code for different branches")
Fixes: 6a98d71d ("RDMA/rtrs: client: main functionality")
Signed-off-by: default avatarGustavo A. R. Silva <gustavoars@kernel.org>
Reviewed-by: default avatarBart Van Assche <bvanassche@acm.org>
Signed-off-by: default avatarJason Gunthorpe <jgg@mellanox.com>
parent bf1d8edb
...@@ -1590,9 +1590,6 @@ static int create_con_cq_qp(struct rtrs_clt_con *con) ...@@ -1590,9 +1590,6 @@ static int create_con_cq_qp(struct rtrs_clt_con *con)
* In case of error we do not bother to clean previous allocations, * In case of error we do not bother to clean previous allocations,
* since destroy_con_cq_qp() must be called. * since destroy_con_cq_qp() must be called.
*/ */
if (err)
return err;
return err; return err;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment