From: "Andreas Bießmann" <biessmann@corscience.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/3] cmd_nvedit: use explicit typecast for printf
Date: Wed, 9 Feb 2011 15:10:29 +0100 [thread overview]
Message-ID: <1297260631-13864-2-git-send-email-biessmann@corscience.de> (raw)
In-Reply-To: <1297260631-13864-1-git-send-email-biessmann@corscience.de>
This patch fixes warnings in MAKEALL for avr32:
---8<---
cmd_nvedit.c: In function 'do_env_export':
cmd_nvedit.c:663: warning: format '%zX' expects type 'size_t', but argument 3 has type 'ssize_t'
--->8---
Signed-off-by: Andreas Bie?mann <biessmann@corscience.de>
---
common/cmd_nvedit.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/common/cmd_nvedit.c b/common/cmd_nvedit.c
index fb69c24..6d8512a 100644
--- a/common/cmd_nvedit.c
+++ b/common/cmd_nvedit.c
@@ -659,7 +659,7 @@ static int do_env_export(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv
errno);
return 1;
}
- sprintf(buf, "%zX", len);
+ sprintf(buf, "%zX", (size_t)len);
setenv("filesize", buf);
return 0;
@@ -685,7 +685,7 @@ static int do_env_export(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv
envp->flags = ACTIVE_FLAG;
#endif
}
- sprintf(buf, "%zX", len + offsetof(env_t,data));
+ sprintf(buf, "%zX", (size_t)(len + offsetof(env_t,data)));
setenv("filesize", buf);
return 0;
--
1.7.2.3
next prev parent reply other threads:[~2011-02-09 14:10 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-09 14:10 [U-Boot] [PATCH 0/3] Get AVR32 boards working with partial linking Andreas Bießmann
2011-02-09 14:10 ` Andreas Bießmann [this message]
2011-04-12 19:44 ` [U-Boot] [PATCH 1/3] cmd_nvedit: use explicit typecast for printf Wolfgang Denk
2011-02-09 14:10 ` [U-Boot] [PATCH 2/3] avr32: fix linking Andreas Bießmann
2011-04-18 10:53 ` Reinhard Meyer
2011-02-09 14:10 ` [U-Boot] [PATCH 3/3] common/cmd_bdinfo.c: fix do_bdinfo() for AVR32 Andreas Bießmann
2011-04-12 19:46 ` Wolfgang Denk
2011-02-09 15:11 ` [U-Boot] [PATCH 0/3] Get AVR32 boards working with partial linking Reinhard Meyer
2011-04-12 19:46 ` Wolfgang Denk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1297260631-13864-2-git-send-email-biessmann@corscience.de \
--to=biessmann@corscience.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox