From cde48f022eb9321ab8a09973dd9139b48bad68da Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Tue, 2 Apr 2024 11:20:06 -0400 Subject: [PATCH] Fix httpGets timeout handling (Issue #879) --- CHANGES.md | 1 + cups/http.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/CHANGES.md b/CHANGES.md index e84c817fa7..44f0726aab 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -26,6 +26,7 @@ Changes in CUPS v2.4.8 (TBA) instead of keywords as `InputSlot` values (Issue #859) - Fixed IPP backend to support the "print-scaling" option with IPP printers (Issue #862) +- Fixed `httpGets` timeout handling (Issue #879) - Fixed checking for required attributes during PPD generation (Issue #890) - Fixed encoding of IPv6 addresses in HTTP requests (Issue #903) - Fixed CGI program initialization and validation of form checkbox and text diff --git a/cups/http.c b/cups/http.c index a73a83b57e..45b95b5e31 100644 --- a/cups/http.c +++ b/cups/http.c @@ -1221,6 +1221,7 @@ httpGets(char *line, /* I - Line to read into */ continue; http->error = WSAGetLastError(); + return (NULL); } else if (WSAGetLastError() != http->error) { @@ -1241,6 +1242,7 @@ httpGets(char *line, /* I - Line to read into */ continue; http->error = errno; + return (NULL); } else if (errno != http->error) { -- 2.47.2