File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ use crate::*;
8
8
/// - `From<Cow<'a, Path>> for Socket<'a>`
9
9
/// - `From<&'a Path> for Socket<'a>`
10
10
/// - `From<PathBuf> for Socket<'a>`
11
+ /// - `From<Box<Path>> for Socket<'a>`
11
12
///
12
13
/// ## Changed
13
14
/// - [`Session::request_port_forward`] now takes `impl Into<...>`
Original file line number Diff line number Diff line change @@ -74,6 +74,14 @@ impl From<PathBuf> for Socket<'static> {
74
74
}
75
75
}
76
76
77
+ impl From < Box < Path > > for Socket < ' static > {
78
+ fn from ( path : Box < Path > ) -> Self {
79
+ Socket :: UnixSocket {
80
+ path : Cow :: Owned ( path. into ( ) ) ,
81
+ }
82
+ }
83
+ }
84
+
77
85
impl Socket < ' _ > {
78
86
/// Create a new TcpSocket
79
87
pub fn new < T : ToSocketAddrs > ( addr : & T ) -> Result < Socket < ' static > , io:: Error > {
You can’t perform that action at this time.
0 commit comments