mtd-utils: fixes verification percent display in flashcp

Message ID 20190211161340.12308-1-drolevar@gmail.com
State New
Delegated to: David Oberhollenzer
Headers show
Series
  • mtd-utils: fixes verification percent display in flashcp
Related show

Commit Message

drolevar@gmail.com Feb. 11, 2019, 4:13 p.m.
From: Andrij Abyzov <drolevar@gmail.com>

flashcp was always showing 0% progress due to incorrect
printf format specifier.

Signed-off-by: Andrij Abyzov <drolevar@gmail.com>
---
 misc-utils/flashcp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

David Oberhollenzer Feb. 28, 2019, 8:12 a.m. | #1
Applied to mtd-utils.git master.

Thanks,

David

Patch

diff --git a/misc-utils/flashcp.c b/misc-utils/flashcp.c
index 0718733..c46a5b4 100644
--- a/misc-utils/flashcp.c
+++ b/misc-utils/flashcp.c
@@ -357,7 +357,7 @@  int main (int argc,char *argv[])
 		if (size < BUFSIZE) i = size;
 		if (flags & FLAG_VERBOSE)
 			log_printf (LOG_NORMAL,
-					"\rVerifying data: %dk/%lluk (%lu%%)",
+					"\rVerifying data: %dk/%lluk (%llu%%)",
 					KB (written + i),
 					KB ((unsigned long long)filestat.st_size),
 					PERCENTAGE (written + i,(unsigned long long)filestat.st_size));