From 6777b2d5196107d92e8d5aac32f00c636240ffd8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rafa=C5=82=20Mi=C5=82ecki?= Date: Fri, 23 Feb 2024 07:18:37 +0100 Subject: [PATCH] uimage_sgehdr: use "char" type for header struct strings MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This fixes: src/uimage_sgehdr.c: In function ‘main’: src/uimage_sgehdr.c:152:10: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness [-Wpointer-sign] strncpy(imgh->sgeih_p, model, sizeof(imgh->sgeih_p)); ^~~~ src/uimage_sgehdr.c:153:10: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness [-Wpointer-sign] strncpy(imgh->sgeih_sv, sversion, sizeof(imgh->sgeih_sv)); ^~~~ src/uimage_sgehdr.c:154:10: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness [-Wpointer-sign] strncpy(imgh->sgeih_hv, hversion, sizeof(imgh->sgeih_hv)); ^~~~ Signed-off-by: Rafał Miłecki --- src/uimage_sgehdr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/uimage_sgehdr.c b/src/uimage_sgehdr.c index 28143a8..6d62c04 100644 --- a/src/uimage_sgehdr.c +++ b/src/uimage_sgehdr.c @@ -40,9 +40,9 @@ struct image_header { uint8_t ih_type; /* Image Type */ uint8_t ih_comp; /* Compression Type */ uint8_t ih_name[IH_NMLEN]; /* Image Name */ - uint8_t sgeih_p[SGE_PRODUCTLEN]; /* sge_Product */ - uint8_t sgeih_sv[SGE_VERSIONLEN]; /* sge Software Version */ - uint8_t sgeih_hv[SGE_VERSIONLEN]; /* sge Hardware Version */ + char sgeih_p[SGE_PRODUCTLEN]; /* sge_Product */ + char sgeih_sv[SGE_VERSIONLEN]; /* sge Software Version */ + char sgeih_hv[SGE_VERSIONLEN]; /* sge Hardware Version */ }; -- 2.30.2