diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2021-07-13 13:58:41 +0000 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2021-07-26 07:06:25 -1000 |
commit | cd1675f8d7fa33b5071a4d3be5dcb69c38300f17 (patch) | |
tree | e2d1b79a11197a7afdedef136291c8cee6fb251a /nbd | |
parent | 2f0e10a4866c16e0b6f98fcc87add047200e4896 (diff) |
nbd/server: Mark variable unused in nbd_negotiate_meta_queries
From clang-13:
nbd/server.c:976:22: error: variable 'bitmaps' set but not used \
[-Werror,-Wunused-but-set-variable]
which is incorrect; see //bugs.llvm.org/show_bug.cgi?id=3888.
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'nbd')
-rw-r--r-- | nbd/server.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/nbd/server.c b/nbd/server.c index b60ebc3ab6..3927f7789d 100644 --- a/nbd/server.c +++ b/nbd/server.c @@ -973,7 +973,8 @@ static int nbd_negotiate_meta_queries(NBDClient *client, { int ret; g_autofree char *export_name = NULL; - g_autofree bool *bitmaps = NULL; + /* Mark unused to work around https://bugs.llvm.org/show_bug.cgi?id=3888 */ + g_autofree G_GNUC_UNUSED bool *bitmaps = NULL; NBDExportMetaContexts local_meta = {0}; uint32_t nb_queries; size_t i; |