← Commit list

aa9fa4d68e

Viktor Szakats
Viktor Szakats
2025-09-22
FAILED Duration: 204s

Subject

rustls: fix clang-tidy warning

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/vtls/rustls.c+3 -1
@@ -410,7 +410,7 @@ read_file_into(const char *filename,
return 0;
}
- while(!feof(f)) {
+ for(;;) {
uint8_t buf[256];
const size_t rr = fread(buf, 1, sizeof(buf), f);
if(rr == 0 ||
@@ -418,6 +418,8 @@ read_file_into(const char *filename,
fclose(f);
return 0;
}
+ if(rr < sizeof(buf))
+ break;
}
return fclose(f) == 0;