summaryrefslogtreecommitdiffstats
path: root/src/tty.rs
diff options
context:
space:
mode:
authorAndy Caldwell <andy.m.caldwell@googlemail.com>2019-02-13 05:12:42 +0000
committerdoug tangren <d.tangren@gmail.com>2019-02-13 00:12:42 -0500
commit2a40dc00e6aeb611db8095dc8646e5132fea356b (patch)
tree30929a1ee4f0386d0879054939eabd12b0a9dcda /src/tty.rs
parent31a913b4a1a6a51179ddd3c3b7b6727984e829e5 (diff)
Copy from container (#150)
* Add 'copy_from' function to 'Container' * Run clippy * Update deps
Diffstat (limited to 'src/tty.rs')
-rw-r--r--src/tty.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/tty.rs b/src/tty.rs
index 038fde0..603c821 100644
--- a/src/tty.rs
+++ b/src/tty.rs
@@ -70,6 +70,12 @@ impl TtyDecoder {
}
}
+impl Default for TtyDecoder {
+ fn default() -> Self {
+ Self::new()
+ }
+}
+
impl Decoder for TtyDecoder {
type Item = Chunk;
type Error = Error;
@@ -226,7 +232,7 @@ where
});
util::stop_on_err(stream, |e| e.kind() != io::ErrorKind::UnexpectedEof)
- .map_err(|e| crate::Error::from(e))
+ .map_err(crate::Error::from)
}
mod util {