[PATCH 1/1] cmd: convert fallthrough comment.

Simon Glass sjg at chromium.org
Sun Apr 2 04:26:28 CEST 2023


On Sat, 1 Apr 2023 at 20:14, Heinrich Schuchardt <
heinrich.schuchardt at canonical.com> wrote:
>
> gcc does not understand /* FALL TROUGH */ and emits a warning:
>
>     cmd/date.c: In function ‘do_date’:
>     cmd/date.c:62:20: warning:
>     this statement may fall through [-Wimplicit-fallthrough=]
>        62 |                 if (strcmp(argv[1],"reset") == 0) {
>           |                    ^
>     cmd/date.c:102:9: note: here
>       102 |         case 1:                 /* get date & time */
>           |         ^~~~
>
> Use the fallthrough macro instead.
>
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at canonical.com>
> ---
>  cmd/date.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>

Reviewed-by: Simon Glass <sjg at chromium.org>


More information about the U-Boot mailing list