From: Tom Rini <trini@konsulko.com>
Date: Wed, 23 Oct 2019 19:39:41 +0000 (-0400)
Subject: Makefile: Fix printing problem in size_check on overflow
X-Git-Tag: v2025.01-rc5-pxa1908~2722^2~24
X-Git-Url: http://git.dujemihanovic.xyz/img/html/static/login.html?a=commitdiff_plain;h=90037eb483d3b84eab214a080e41efde85d9f2de;p=u-boot.git

Makefile: Fix printing problem in size_check on overflow

When we have an excess size growth, fix the "limit" printf call to pass
in just the limit variable rather than the string bytes to the format
character.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
---

diff --git a/Makefile b/Makefile
index 58a5721b3d..a96c6ce81e 100644
--- a/Makefile
+++ b/Makefile
@@ -346,7 +346,7 @@ define size_check
 	limit=$$( printf "%d" $2 ); \
 	if test $$actual -gt $$limit; then \
 		echo "$1 exceeds file size limit:" >&2; \
-		echo "  limit:  $$(printf %#x bytes $$limit) bytes" >&2; \
+		echo "  limit:  $$(printf %#x $$limit) bytes" >&2; \
 		echo "  actual: $$(printf %#x $$actual) bytes" >&2; \
 		echo "  excess: $$(printf %#x $$((actual - limit))) bytes" >&2;\
 		exit 1; \