9
0
Fork 0

progressbar: use __stringify in format string

Use stringify in format string for HASH_PER_LINE.

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
Alexander Aring 2012-10-21 22:59:06 +02:00 committed by Sascha Hauer
parent de053ed91c
commit 4d5fa6ca5c
1 changed files with 2 additions and 1 deletions

View File

@ -20,6 +20,7 @@
#include <common.h>
#include <progress.h>
#include <asm-generic/div64.h>
#include <linux/stringify.h>
#define HASHES_PER_LINE 65
@ -56,7 +57,7 @@ void init_progression_bar(int max)
progress_max = max;
spin = 0;
if (progress_max)
printf("\t[%65s]\r\t[", "");
printf("\t[%"__stringify(HASHES_PER_LINE)"s]\r\t[", "");
else
printf("\t");
}