Patch fixes this issue:
fw_env.c: In function ‘fw_setenv’:
fw_env.c:492:5: warning: format ‘%u’ expects argument of type ‘unsigned int’, but argument 3 has type ‘size_t’ [-Wformat]
fw_env.c: In function ‘flash_write_buf’:
fw_env.c:806:6: warning: format ‘%u’ expects argument of type ‘unsigned int’, but argument 3 has type ‘size_t’ [-Wformat]
Signed-off-by: Luka Perkov <lists@lukaperkov.net>
Acked-by: Mike Frysinger <vapier@gentoo.org>
[sw0312.kim: backport mainline commit
8603b69b8b04 to remove gcc 9 build warning]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I333ce3a5bf4caf3eed4272cf79b837eab48776a0
value = (char *)malloc(len - strlen(name));
if (!value) {
fprintf(stderr,
- "Cannot malloc %u bytes: %s\n",
+ "Cannot malloc %zu bytes: %s\n",
len - strlen(name), strerror(errno));
return -1;
}
data = malloc (erase_len);
if (!data) {
fprintf (stderr,
- "Cannot malloc %u bytes: %s\n",
+ "Cannot malloc %zu bytes: %s\n",
erase_len, strerror (errno));
return -1;
}