servo: Merge #3782 - Fix cef warnings (from Ms2ger:cef-warnings); r=Ms2ger,metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: 979608dbb1ce0e52d109f735c80e31e8b6a0447a
This commit is contained in:
Ms2ger 2014-10-23 17:18:40 -06:00
parent 359050268f
commit 9c49fdd1cf
3 changed files with 5 additions and 5 deletions

View File

@ -3,7 +3,6 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use azure;
use command_line::command_line_init;
use eutil::fptr_is_null;
use geom::size::TypedSize2D;
@ -49,7 +48,7 @@ pub extern "C" fn cef_shutdown() {
pub extern "C" fn cef_run_message_loop() {
let mut urls = Vec::new();
urls.push("http://s27.postimg.org/vqbtrolyr/servo.jpg".to_string());
let opts = opts::Opts {
opts::set_opts(opts::Opts {
urls: urls,
n_render_threads: 1,
gpu_painting: false,
@ -75,7 +74,7 @@ pub extern "C" fn cef_run_message_loop() {
user_agent: None,
dump_flow_tree: false,
validate_display_list_geometry: false,
};
});
native::start(0, 0 as *const *const u8, proc() {
let window = Some(glfw_app::create_window());
servo::run(window);

View File

@ -5,6 +5,7 @@
#![feature(globs, macro_rules, phase, thread_local, link_args)]
#![allow(experimental, non_camel_case_types)]
#![deny(unused_imports, unused_variable, unused_mut)]
#![feature(phase)]
#[phase(plugin, link)]

View File

@ -49,8 +49,8 @@ pub extern "C" fn cef_string_list_value(lt: *mut cef_string_list_t, index: c_int
if index < 0 || fptr_is_null(mem::transmute(lt)) { return 0; }
let v = string_map_to_vec(lt);
if index as uint > (*v).len() - 1 { return 0; }
let cs = (*v).get(index as uint);
cef_string_utf8_set(mem::transmute((**cs).str), (**cs).length, value, 1)
let cs = (*v)[index as uint];
cef_string_utf8_set(mem::transmute((*cs).str), (*cs).length, value, 1)
}
}