From 2c7de7e0fbd231073f1354769484d1751071285d Mon Sep 17 00:00:00 2001 From: Naja Melan Date: Wed, 13 Mar 2019 08:41:26 +0100 Subject: [PATCH] Fix compiler warnings. Compiles in stable and nightly --- actix-rt/src/runtime.rs | 2 +- actix-rt/src/system.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/actix-rt/src/runtime.rs b/actix-rt/src/runtime.rs index e5269141..d98f85da 100644 --- a/actix-rt/src/runtime.rs +++ b/actix-rt/src/runtime.rs @@ -41,7 +41,7 @@ impl Error for RunError { self.inner.description() } fn cause(&self) -> Option<&Error> { - self.inner.cause() + self.inner.source() } } diff --git a/actix-rt/src/system.rs b/actix-rt/src/system.rs index 7fe31448..aaf15c7c 100644 --- a/actix-rt/src/system.rs +++ b/actix-rt/src/system.rs @@ -1,13 +1,13 @@ use std::cell::RefCell; use std::io; -use std::sync::atomic::{AtomicUsize, Ordering, ATOMIC_USIZE_INIT}; +use std::sync::atomic::{AtomicUsize, Ordering}; use futures::sync::mpsc::UnboundedSender; use crate::arbiter::{Arbiter, SystemCommand}; use crate::builder::{Builder, SystemRunner}; -static SYSTEM_COUNT: AtomicUsize = ATOMIC_USIZE_INIT; +static SYSTEM_COUNT: AtomicUsize = AtomicUsize::new(0); /// System is a runtime manager. #[derive(Clone, Debug)]