[fixup] return that reading from a null stream wrote 0 bytes to the buffer

This commit is contained in:
Emilie Burgun
2025-02-07 14:35:27 +01:00
parent 7108e87e92
commit 8966e175f1

View File

@@ -836,7 +836,7 @@ impl Read for Stream {
ErrorKind::PermissionDenied,
StreamError::ReadFromOutputStream,
)),
Stream::Null(_) => Ok(buf.len()),
Stream::Null(_) => Ok(0),
Stream::OutputFile(_) | Stream::StandardError(_) | Stream::StandardOutput(_) => {
Err(std::io::Error::new(
ErrorKind::PermissionDenied,