From d868cddb0933c8fef7297ae5f5da905faeb9b268 Mon Sep 17 00:00:00 2001 From: Oriol Brufau Date: Fri, 11 Aug 2023 00:19:55 +0200 Subject: [PATCH] Further changes required by Servo --- components/style/global_style_data.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/components/style/global_style_data.rs b/components/style/global_style_data.rs index 0269012e913..576ac425b5a 100644 --- a/components/style/global_style_data.rs +++ b/components/style/global_style_data.rs @@ -17,7 +17,6 @@ use rayon; use std::env; use std::io; use std::thread; -use std::sync::Mutex; /// Global style data pub struct GlobalStyleData { @@ -117,7 +116,7 @@ impl StyleThreadPool { lazy_static! { /// Global thread pool - pub static ref STYLE_THREAD_POOL: Mutex = { + pub static ref STYLE_THREAD_POOL: std::sync::Mutex = { let stylo_threads = env::var("STYLO_THREADS") .map(|s| s.parse::().expect("invalid STYLO_THREADS value")); let mut num_threads = match stylo_threads { @@ -171,7 +170,7 @@ lazy_static! { workers.ok() }; - Mutex::new(StyleThreadPool { + std::sync::Mutex::new(StyleThreadPool { num_threads: if num_threads > 0 { Some(num_threads) } else {