Skip to content

Commit 9d56b91

Browse files
sfacklertikue
andauthored
Update text/0000-read-buf.md
Co-authored-by: Tim <[email protected]>
1 parent ba39794 commit 9d56b91

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

text/0000-read-buf.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ impl Read for TcpStream {
221221

222222
// We're just delegating to the libc read function, which returns an `isize`. The return value indicates
223223
// an error if negative and the number of bytes read otherwise.
224-
let nread = libc::read(self.fd, unwritten.as_mut_ptr().cast::<libc::c_void>(), unwritten.len());
224+
let nread = libc::read(self.fd, unfilled.as_mut_ptr().cast::<libc::c_void>(), unfilled.len());
225225

226226
if nread < 0 {
227227
return Err(io::Error::last_os_error());

0 commit comments

Comments
 (0)