diff options
author | Kees Cook <[email protected]> | 2021-12-08 20:39:15 -0800 |
---|---|---|
committer | Alexandre Belloni <[email protected]> | 2022-01-05 01:03:09 +0100 |
commit | ba52eac083e1598e748811ff58d259f77e4c5c4d (patch) | |
tree | 74dff1ec57759c0d82e61196bfc5305bf4d175d2 /scripts/gdb/linux/tasks.py | |
parent | 7b69b54aaa48979f5e3cebb7225e11cbbdc9f5fb (diff) |
rtc: Move variable into switch case statement
When building with automatic stack variable initialization, GCC 12
complains about variables defined outside of switch case statements.
Move the variable into the case that uses it, which silences the warning:
drivers/rtc/dev.c: In function 'rtc_dev_ioctl':
drivers/rtc/dev.c:394:30: warning: statement will never be executed [-Wswitch-unreachable]
394 | long offset;
| ^~~~~~
Fixes: 6a8af1b6568a ("rtc: add parameter ioctl")
Signed-off-by: Kees Cook <[email protected]>
Reviewed-by: Gustavo A. R. Silva <[email protected]>
Signed-off-by: Alexandre Belloni <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'scripts/gdb/linux/tasks.py')
0 files changed, 0 insertions, 0 deletions