mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Remove some as_slice calls.
This commit is contained in:
parent
4ee89363fb
commit
6a55ae06d7
34 changed files with 79 additions and 79 deletions
|
@ -233,7 +233,7 @@ impl ImageCache {
|
|||
ResponseAction::HeadersAvailable(_) => {}
|
||||
ResponseAction::DataAvailable(data) => {
|
||||
let pending_load = self.pending_loads.get_mut(&msg.url).unwrap();
|
||||
pending_load.bytes.push_all(data.as_slice());
|
||||
pending_load.bytes.push_all(&data);
|
||||
}
|
||||
ResponseAction::ResponseComplete(result) => {
|
||||
match result {
|
||||
|
@ -246,7 +246,7 @@ impl ImageCache {
|
|||
let sender = self.decoder_sender.clone();
|
||||
|
||||
self.task_pool.execute(move || {
|
||||
let image = load_from_memory(bytes.as_slice());
|
||||
let image = load_from_memory(&bytes);
|
||||
let msg = DecoderMsg {
|
||||
url: url,
|
||||
image: image
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue