mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Remove as_mut_slice() calls.
This commit is contained in:
parent
a862479ca8
commit
9185c3de79
6 changed files with 7 additions and 7 deletions
|
@ -23,7 +23,7 @@ enum ReadStatus {
|
|||
|
||||
fn read_block(reader: &mut File) -> Result<ReadStatus, String> {
|
||||
let mut buf = vec![0; READ_SIZE];
|
||||
match reader.read(buf.as_mut_slice()) {
|
||||
match reader.read(&mut buf) {
|
||||
Ok(0) => return Ok(ReadStatus::EOF),
|
||||
Ok(n) => {
|
||||
buf.truncate(n);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue