summaryrefslogtreecommitdiffstats
path: root/src/message.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/message.rs')
-rw-r--r--src/message.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/message.rs b/src/message.rs
index b7076d5..094720e 100644
--- a/src/message.rs
+++ b/src/message.rs
@@ -72,8 +72,8 @@ impl Message {
let mut w = io::MemWriter::new();
// this should never fail, so unwrap is fine
self.write_protocol_string(&mut w).unwrap();
- // XXX error handling, encoding
- String::from_utf8(w.unwrap()).unwrap()
+ // XXX encoding
+ String::from_utf8_lossy(w.unwrap().as_slice()).into_string()
}
fn parse_params(params: &str) -> Vec<String> {