Re: [PATCH] block: rnbd: rnbd-srv: silence uninitialized variable warning

2020-08-18 Thread Brooke Basile
On 8/18/20 1:29 AM, Nathan Chancellor wrote: I don't think this is a proper fix since the root cause of the warning appears to be that we are ignoring the return value of rnbd_bio_map_kern. Should we not set err to that value like this (completely untested)? Cheers, Nathan diff --git a/drivers/

Re: [PATCH] block: rnbd: rnbd-srv: silence uninitialized variable warning

2020-08-17 Thread Jinpu Wang
On Tue, Aug 18, 2020 at 7:30 AM Nathan Chancellor wrote: > > On Tue, Aug 18, 2020 at 12:03:18AM -0400, Brooke Basile wrote: > > Clang warns: > > drivers/block/rnbd/rnbd-srv.c:150:6: warning: variable 'err' is used > > uninitialized whenever 'if' condition is true > > [-Wsometimes-unin

Re: [PATCH] block: rnbd: rnbd-srv: silence uninitialized variable warning

2020-08-17 Thread Nathan Chancellor
On Tue, Aug 18, 2020 at 12:03:18AM -0400, Brooke Basile wrote: > Clang warns: > drivers/block/rnbd/rnbd-srv.c:150:6: warning: variable 'err' is used > uninitialized whenever 'if' condition is true > [-Wsometimes-uninitialized] > if (IS_ERR(bio)) { > ^~~~

[PATCH] block: rnbd: rnbd-srv: silence uninitialized variable warning

2020-08-17 Thread Brooke Basile
Clang warns: drivers/block/rnbd/rnbd-srv.c:150:6: warning: variable 'err' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized] if (IS_ERR(bio)) { ^~~ drivers/block/rnbd/rnbd-srv.c:177:9: note: uninitialize