tools: imx image: fix write warning
Fix the warning by set the variable zero to uint64_t
"warning: ‘write’ reading 5 bytes from a region of size 4"
Signed-off-by: Peng Fan <peng.fan@nxp.com>
diff --git a/tools/imx8image.c b/tools/imx8image.c
index 133780f..fa8f227 100644
--- a/tools/imx8image.c
+++ b/tools/imx8image.c
@@ -365,7 +365,7 @@
struct stat sbuf;
unsigned char *ptr;
int tail;
- int zero = 0;
+ uint64_t zero = 0;
uint8_t zeros[4096];
int size, ret;
diff --git a/tools/imx8mimage.c b/tools/imx8mimage.c
index 9985b95..11e40cc 100644
--- a/tools/imx8mimage.c
+++ b/tools/imx8mimage.c
@@ -248,7 +248,7 @@
struct stat sbuf;
unsigned char *ptr;
int tail;
- int zero = 0;
+ uint64_t zero = 0;
uint8_t zeros[4096];
int size, ret;