mirror of
https://github.com/servo/servo.git
synced 2025-08-02 20:20:14 +01:00
Fix warnings: Use Vec.extend_from_slice instead of Vec.push_all
This commit is contained in:
parent
b756375637
commit
e8c12c1c6d
17 changed files with 23 additions and 30 deletions
|
@ -8,7 +8,6 @@
|
|||
#![feature(plugin)]
|
||||
#![feature(slice_patterns)]
|
||||
#![feature(step_by)]
|
||||
#![feature(vec_push_all)]
|
||||
#![feature(custom_attribute)]
|
||||
#![plugin(serde_macros, plugins)]
|
||||
|
||||
|
@ -423,7 +422,7 @@ pub fn load_whole_resource(resource_task: &ResourceTask, url: Url, pipeline_id:
|
|||
let mut buf = vec!();
|
||||
loop {
|
||||
match response.progress_port.recv().unwrap() {
|
||||
ProgressMsg::Payload(data) => buf.push_all(&data),
|
||||
ProgressMsg::Payload(data) => buf.extend_from_slice(&data),
|
||||
ProgressMsg::Done(Ok(())) => return Ok((response.metadata, buf)),
|
||||
ProgressMsg::Done(Err(e)) => return Err(e)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue