Correct sscanf formatting to indicate if a reboot is not required.
Signed-off-by: Matt Wood <
matt...@microchip.com>
---
tools/swupdate-progress.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/swupdate-progress.c b/tools/swupdate-progress.c
index 14040757..5e371627 100644
--- a/tools/swupdate-progress.c
+++ b/tools/swupdate-progress.c
@@ -354,7 +354,7 @@ int main(int argc, char **argv)
* will be added, JSON lib should be linked.
* NOTE: Until then, the exact string format is imperative!
*/
- n = sscanf(
msg.info, "{\"%*d\": {\"%d\": { \"reboot-mode\" : \"%19[-a-z]\"}}}",
+ n = sscanf(
msg.info, "{\"%d\": { \"reboot-mode\" : \"%19[-a-z]\"}}",
&cause, reboot_mode);
if (n == 2) {
if (cause == CAUSE_REBOOT_MODE) {
--
2.34.1