Remove unused unsafe declarations (#1901)

This commit is contained in:
hashmap 2018-10-31 21:19:28 +01:00 committed by Ignotus Peverell
parent 385b385456
commit b01fcd2f56
5 changed files with 0 additions and 15 deletions

View file

@ -41,9 +41,6 @@ pub struct Handshake {
config: P2PConfig, config: P2PConfig,
} }
unsafe impl Sync for Handshake {}
unsafe impl Send for Handshake {}
impl Handshake { impl Handshake {
/// Creates a new handshake handler /// Creates a new handshake handler
pub fn new(genesis: Hash, config: P2PConfig) -> Handshake { pub fn new(genesis: Hash, config: P2PConfig) -> Handshake {

View file

@ -52,9 +52,6 @@ pub struct Peer {
connection: Option<conn::Tracker>, connection: Option<conn::Tracker>,
} }
unsafe impl Sync for Peer {}
unsafe impl Send for Peer {}
impl Peer { impl Peer {
// Only accept and connect can be externally used to build a peer // Only accept and connect can be externally used to build a peer
fn new(info: PeerInfo, adapter: Arc<NetAdapter>) -> Peer { fn new(info: PeerInfo, adapter: Arc<NetAdapter>) -> Peer {

View file

@ -41,9 +41,6 @@ pub struct Server {
stop: Arc<AtomicBool>, stop: Arc<AtomicBool>,
} }
unsafe impl Sync for Server {}
unsafe impl Send for Server {}
// TODO TLS // TODO TLS
impl Server { impl Server {
/// Creates a new idle p2p server with no peers /// Creates a new idle p2p server with no peers

View file

@ -36,9 +36,6 @@ pub struct LeafSet {
bitmap_bak: Bitmap, bitmap_bak: Bitmap,
} }
unsafe impl Send for LeafSet {}
unsafe impl Sync for LeafSet {}
impl LeafSet { impl LeafSet {
/// Open the remove log file. /// Open the remove log file.
/// The content of the file will be read in memory for fast checking. /// The content of the file will be read in memory for fast checking.

View file

@ -51,9 +51,6 @@ pub struct PruneList {
leaf_shift_cache: Vec<u64>, leaf_shift_cache: Vec<u64>,
} }
unsafe impl Send for PruneList {}
unsafe impl Sync for PruneList {}
impl PruneList { impl PruneList {
/// Instantiate a new empty prune list /// Instantiate a new empty prune list
pub fn new() -> PruneList { pub fn new() -> PruneList {