]> git.ipfire.org Git - thirdparty/curl.git/commit
rustls: make read_file_into not reject good files
authorDaniel Stenberg <daniel@haxx.se>
Fri, 17 Oct 2025 15:05:08 +0000 (17:05 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 17 Oct 2025 15:44:14 +0000 (17:44 +0200)
commite9455ea523d91c8f6f29c3ae1f37500f0b637204
tree766b6c8abf557f563c4120c9e13e917ef5b486db
parent373855a4da0882ccb07a1b80b3754c80acc0d502
rustls: make read_file_into not reject good files

For files with sizes using an exact multiple of 256 bytes, the final
successful read(s) filled the buffer(s) and the subsequent fread
returned 0 for EOF, which caused read_file_into to fail.

Now, it needs to return 0 and not be EOF to be an error.

Follow-up to dd95a49d493d55db38b352fdbda2

Pointed out by ZeroPath
Closes #19104
lib/vtls/rustls.c