mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Use Box::into_raw rather than boxed::into_raw.
The latter is deprecated.
This commit is contained in:
parent
ea06bebca9
commit
28086f3c75
4 changed files with 8 additions and 12 deletions
|
@ -23,7 +23,7 @@ use hyper::header::{ContentType, Header, SetCookie, UserAgent};
|
|||
use hyper::mime::{Mime, TopLevel, SubLevel};
|
||||
|
||||
use std::borrow::ToOwned;
|
||||
use std::boxed::{self, FnBox};
|
||||
use std::boxed::FnBox;
|
||||
use std::collections::HashMap;
|
||||
use std::env;
|
||||
use std::fs::File;
|
||||
|
@ -52,8 +52,8 @@ pub fn global_init() {
|
|||
Err(_) => return,
|
||||
};
|
||||
|
||||
let host_table = Box::into_raw(parse_hostsfile(&lines));
|
||||
unsafe {
|
||||
let host_table = boxed::into_raw(parse_hostsfile(&lines));
|
||||
HOST_TABLE = Some(host_table);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue