Skip to content

Commit 15ce6e0

Browse files
tpambordkalowsk
authored andcommitted
shell: Fix warning for SHELL_SUBCMD_SET_END
The macro SHELL_SUBCMD_SET_END was defined as {NULL}, which triggers a -Wmissing-field-initializers warning due to the missing 'help' field in the shell_cmd struct. Replacing {NULL} with {0} silences the warning. Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
1 parent 089c461 commit 15ce6e0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/zephyr/shell/shell.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ static inline bool shell_help_is_structured(const char *help)
510510
* @brief Define ending subcommands set.
511511
*
512512
*/
513-
#define SHELL_SUBCMD_SET_END {NULL}
513+
#define SHELL_SUBCMD_SET_END {0}
514514

515515
/**
516516
* @brief Macro for creating a dynamic entry.

0 commit comments

Comments
 (0)