← Commit list

ae09e5bf0d

Daniel Stenberg
Daniel Stenberg
2026-03-17
SUCCESS Duration: 249s

Subject

curl_get_line: error out on read errors

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

lib/curl_get_line.c+2 -0
@@ -40,6 +40,8 @@ CURLcode Curl_get_line(struct dynbuf *buf, FILE *input, bool *eof)
while(1) {
size_t rlen;
const char *b = fgets(buffer, sizeof(buffer), input);
+ if(!b && ferror(input))
+ return CURLE_READ_ERROR;
*eof = feof(input);