thread: fix set-but-unused warning
In release builds, the assert() is compiled out, making it look like the rc value is never referenced after it's set. Signed-off-by: Jim Harris <james.r.harris@intel.com> Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/473472 (master) (cherry picked from commit 750f2b4b3d59a9cd23bf8c50ed3c4774eddda8e7) Change-Id: I59305b0e928f2044146e30b7addc86f81e7a1d3f Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/478584 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Alexey Marchuk <alexeymar@mellanox.com>
This commit is contained in:
parent
a2c3412dd8
commit
90c4efcb63
@ -1199,7 +1199,7 @@ spdk_for_each_channel(void *io_device, spdk_channel_msg fn, void *ctx,
|
||||
struct spdk_thread *thread;
|
||||
struct spdk_io_channel *ch;
|
||||
struct spdk_io_channel_iter *i;
|
||||
int rc;
|
||||
int rc __attribute__((unused));
|
||||
|
||||
i = calloc(1, sizeof(*i));
|
||||
if (!i) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user