From f184b45e0953e502857cdc0da3b1b039f81e4892 Mon Sep 17 00:00:00 2001 From: Anton Lundin Date: Tue, 10 Feb 2015 07:39:56 +0100 Subject: [PATCH] Correct firmware version string from OSTC's The format string was incorrect, producing firmware numbers as 3.2 instead of 3.02 as is the current OSTC firmware version. This was reported via hw's forum: http://forum.heinrichsweikamp.com/read.php?2,14550,14552 Signed-off-by: Anton Lundin Signed-off-by: Dirk Hohndel --- src/hw_ostc_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hw_ostc_parser.c b/src/hw_ostc_parser.c index 0da1083..6db9d27 100644 --- a/src/hw_ostc_parser.c +++ b/src/hw_ostc_parser.c @@ -554,7 +554,7 @@ hw_ostc_parser_get_field (dc_parser_t *abstract, dc_field_type_t type, unsigned break; case 2: /* fw_version */ string->desc = "FW Version"; - snprintf(buf, BUFLEN, "%0u.%0u", data[layout->fw_version], data[layout->fw_version + 1]); + snprintf(buf, BUFLEN, "%0u.%02u", data[layout->fw_version], data[layout->fw_version + 1]); break; case 3: /* serial */ string->desc = "Serial";