From 98d8cd52df444372bf9f1cc886f824919351c276 Mon Sep 17 00:00:00 2001 From: scott Date: Fri, 21 Mar 2025 16:24:02 -0700 Subject: [PATCH] Fixes an issue with the long-form Command Header where the Parameter List Length (2nd word) incorrectly included the padding octet --- modules/c/cgm/source/MetafileWriter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/c/cgm/source/MetafileWriter.c b/modules/c/cgm/source/MetafileWriter.c index 4e64b4bcc..5d2223af8 100644 --- a/modules/c/cgm/source/MetafileWriter.c +++ b/modules/c/cgm/source/MetafileWriter.c @@ -54,9 +54,9 @@ NITFPRIV(NITF_BOOL) writeHeader(short classType, short code, short size, (*actual)++; } - if (*actual >= 31) + if (size >= 31) { - extendedParams = *actual; + extendedParams = size; params = 31; }