Rocket/core
Paul Lietar 67ad8316dc Ensure 'TempFile' flushes when persisted.
Tokio's `File::write_all()` method has an unexpected quirk: it doesn't
actually write all the requested content to the file when the returned
future resolves. Instead, the write is attempted and queued. This means
that the `persist()` method can resolve without the data being persisted
to the file system. Subsequent reads of the ostensibly written-to file
can thus fail to contain the expected data.

An call to `flush()` following `write_all()` would circumvent the issue.
Alternatively, calling `fs::write()` actually writes to the file system
before returning and requires fewer lines of code. This commit thus
swaps the call to `write_all()` with `fs::write()`.
2023-12-19 16:01:00 -08:00
..
codegen Fix min dependency versions. Update MSRV to 1.64. 2023-12-13 17:49:05 -08:00
http Upgrade 'rustls' to '0.22'. 2023-12-15 16:50:08 -08:00
lib Ensure 'TempFile' flushes when persisted. 2023-12-19 16:01:00 -08:00