From 0ee3b4c136ccf7e9b66f2610a6d7f3ac4c135d14 Mon Sep 17 00:00:00 2001 From: Simon Horman Date: Tue, 6 Sep 2011 07:10:08 +0900 Subject: Use unsigned char buffers in uImage loader This avoids out of range comparisons (for values >= 128) and an unnecessary cast. Signed-off-by: Simon Horman --- include/kexec-uImage.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/kexec-uImage.h b/include/kexec-uImage.h index e8a4b69..8c7707d 100644 --- a/include/kexec-uImage.h +++ b/include/kexec-uImage.h @@ -2,12 +2,12 @@ #define __KEXEC_UIMAGE_H__ struct Image_info { - const char *buf; + const unsigned char *buf; off_t len; unsigned int base; unsigned int ep; }; -int uImage_probe(const char *buf, off_t len, unsigned int arch); -int uImage_load(const char *buf, off_t len, struct Image_info *info); +int uImage_probe(const unsigned char *buf, off_t len, unsigned int arch); +int uImage_load(const unsigned char *buf, off_t len, struct Image_info *info); #endif -- cgit