aboutsummaryrefslogtreecommitdiffstats
path: root/src/platform/dummy/bind.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/platform/dummy/bind.rs26
1 files changed, 2 insertions, 24 deletions
diff --git a/src/platform/dummy/bind.rs b/src/platform/dummy/bind.rs
index 14143ae..5010597 100644
--- a/src/platform/dummy/bind.rs
+++ b/src/platform/dummy/bind.rs
@@ -1,13 +1,14 @@
use std::error::Error;
use std::fmt;
use std::marker;
-use std::net::SocketAddr;
+
use std::sync::mpsc::{sync_channel, Receiver, SyncSender};
use std::sync::Arc;
use std::sync::Mutex;
use super::super::bind::*;
use super::super::Endpoint;
+use super::UnitEndpoint;
pub struct VoidOwner {}
@@ -57,29 +58,6 @@ impl fmt::Display for TunError {
}
}
-/* Endpoint implementation */
-
-#[derive(Clone, Copy)]
-pub struct UnitEndpoint {}
-
-impl Endpoint for UnitEndpoint {
- fn from_address(_: SocketAddr) -> UnitEndpoint {
- UnitEndpoint {}
- }
-
- fn into_address(&self) -> SocketAddr {
- "127.0.0.1:8080".parse().unwrap()
- }
-
- fn clear_src(&mut self) {}
-}
-
-impl UnitEndpoint {
- pub fn new() -> UnitEndpoint {
- UnitEndpoint {}
- }
-}
-
#[derive(Clone, Copy)]
pub struct VoidBind {}