From 25616112983cd3f8bfe5379771b5bfd63b3c3621 Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Sun, 12 Feb 2023 09:23:09 -0800 Subject: XpmCreateDataFromXpmImage: Fix misleading indentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit CrDatFrI.c: In function ‘XpmCreateDataFromXpmImage’: CrDatFrI.c:245:13: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation] 245 | if (header[l]) | ^~ In file included from CrDatFrI.c:40: XpmI.h:80:22: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’ 80 | #define XpmFree(ptr) free(ptr) | ^~~~ CrDatFrI.c:247:17: note: in expansion of macro ‘XpmFree’ 247 | XpmFree(header); | ^~~~~~~ CrDatFrI.c: In function ‘CreateColors’: Signed-off-by: Alan Coopersmith --- src/CrDatFrI.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/CrDatFrI.c b/src/CrDatFrI.c index 542662f..adb4786 100644 --- a/src/CrDatFrI.c +++ b/src/CrDatFrI.c @@ -241,10 +241,11 @@ XpmCreateDataFromXpmImage( /* exit point, free only locally allocated variables */ exit: if (header) { - for (l = 0; l < header_nlines; l++) + for (l = 0; l < header_nlines; l++) { if (header[l]) XpmFree(header[l]); - XpmFree(header); + } + XpmFree(header); } return(ErrorStatus); } -- cgit v1.2.1