From 349c48050475ec64f63d367e00c1dcc764c7acda Mon Sep 17 00:00:00 2001 From: "Sven M. Hallberg" <pesco@khjk.org> Date: Sat, 23 Nov 2019 21:26:19 +0100 Subject: [PATCH] fix Length comparison --- pdf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pdf.c b/pdf.c index d8d0298..8dc491b 100644 --- a/pdf.c +++ b/pdf.c @@ -353,7 +353,7 @@ kstream(HAllocator *mm__, const HParsedToken *x, void *env) ent = dict->elements[i]; k = H_INDEX_BYTES(ent, 0); - if (strncmp("Length", k.token, k.len) == 0) { // XXX strncasecmp? + if (k.len == 6 && strncmp("Length", k.token, k.len) == 0) { v = H_INDEX_TOKEN(ent, 1); break; } -- GitLab