From cc7f3e38f901855249d02bfb4f920ab5c19a2975 Mon Sep 17 00:00:00 2001 From: Aizal Khan Date: Wed, 1 Jul 2026 13:29:30 +0530 Subject: [PATCH] stop response skip loop at nul in commandtops --- filter/commandtops.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/filter/commandtops.c b/filter/commandtops.c index c0c38945d0..c19b16d894 100644 --- a/filter/commandtops.c +++ b/filter/commandtops.c @@ -318,7 +318,7 @@ auto_configure(ppd_file_t *ppd, /* I - PPD file */ else break; - for (bufptr = buffer; isspace(*bufptr & 255) || iscntrl(*bufptr & 255); + for (bufptr = buffer; *bufptr && (isspace(*bufptr & 255) || iscntrl(*bufptr & 255)); bufptr ++); if (bufptr > buffer)