mirror of
https://github.com/SCST-project/scst.git
synced 2026-08-17 04:36:22 +00:00
usr/fileio/common.c: Fix warning for older versions of GCC
Building SCST with an old version of GCC (e.g. 4.8.5 on Centos 7.X)
produces a warning about using initializer.
This is GCC bug # 53119:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53119
Hence, use memset() instead of an initializer to avoid this warning.
Fixes: e8b300ef2a ("usr/fileio/common.c: Fix use of uninitialized
struct field")
This commit is contained in:
+3
-1
@@ -792,7 +792,9 @@ void *main_loop(void *arg)
|
||||
struct scst_user_reply_cmd replies[MULTI_CMDS_CNT];
|
||||
struct scst_user_get_multi multi_cmd;
|
||||
struct scst_user_get_cmd cmds[MULTI_CMDS_CNT];
|
||||
} multi = {};
|
||||
} multi;
|
||||
|
||||
memset(&multi, 0, sizeof(multi));
|
||||
|
||||
TRACE_ENTRY();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user