Commit f366956
fix(cmd_status): function-scope keys so the coverage/firmware build compiles
Rebasing onto current master pulled in a latent build break: cmd_status
declares `keys` inside the `if (commands_is_admin())` block but scrubs it
via `secure_wipe(keys, sizeof(keys))` at function scope, so `keys` is
undeclared there. asan_commands links serial/commands.c (not
commands_system.c) so it never compiled this TU, but `make -C test coverage`
compiles the whole first-party surface and fails here (`keys undeclared`) --
as does the real firmware build. Restore `keys` to function scope, matching
the scrub's intent of always clearing the key DB from BSS (incl. the
non-admin path where it stays zero-initialised). Same fix as PR hakierspejs#15 (M1).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent c9d715a commit f366956
1 file changed
Lines changed: 6 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
68 | 71 | | |
69 | | - | |
70 | | - | |
71 | | - | |
| 72 | + | |
| 73 | + | |
72 | 74 | | |
73 | 75 | | |
74 | 76 | | |
| |||
0 commit comments