diff options
author | Eduard Burtescu <edy.burt@gmail.com> | 2016-07-04 20:59:01 +0300 |
---|---|---|
committer | Eduard Burtescu <edy.burt@gmail.com> | 2016-07-04 20:59:01 +0300 |
commit | 0db1faf87651c99223683faafc836353f016ffb3 (patch) | |
tree | dec7ee5366fdb60a47f495d32c11a9ed2b8a4eb2 /components/script/timers.rs | |
parent | a77cc9950fb13ccd674a10e46c2327bfa0735dab (diff) | |
download | servo-0db1faf87651c99223683faafc836353f016ffb3.tar.gz servo-0db1faf87651c99223683faafc836353f016ffb3.zip |
Switch to using the new rooted!/RootedGuard API for rooting.
Diffstat (limited to 'components/script/timers.rs')
-rw-r--r-- | components/script/timers.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/timers.rs b/components/script/timers.rs index 989382e80fe..f2562bdf9d5 100644 --- a/components/script/timers.rs +++ b/components/script/timers.rs @@ -13,7 +13,7 @@ use dom::xmlhttprequest::XHRTimeoutCallback; use euclid::length::Length; use heapsize::HeapSizeOf; use ipc_channel::ipc::IpcSender; -use js::jsapi::{HandleValue, Heap, RootedValue}; +use js::jsapi::{HandleValue, Heap}; use js::jsval::{JSVal, UndefinedValue}; use script_traits::{MsDuration, precise_time_ms}; use script_traits::{TimerEvent, TimerEventId, TimerEventRequest, TimerSource}; @@ -488,7 +488,7 @@ impl JsTimerTask { match *&self.callback { InternalTimerCallback::StringTimerCallback(ref code_str) => { let cx = this.global().r().get_cx(); - let mut rval = RootedValue::new(cx, UndefinedValue()); + rooted!(in(cx) let mut rval = UndefinedValue()); this.evaluate_js_on_global_with_result(code_str, rval.handle_mut()); }, |