@@ -11,12 +11,10 @@ use czmq;
1111use libc:: c_char;
1212use mustache;
1313use regex;
14- use rustc_serialize:: json;
1514use serde_json;
1615use std:: { convert, error, ffi, fmt, io, num, ptr, result, str, string} ;
1716use std:: any:: Any ;
1817use std:: ffi:: CString ;
19- use zdaemon;
2018#[ cfg( feature = "remote-run" ) ]
2119use zfilexfer;
2220
@@ -70,8 +68,6 @@ pub enum Error {
7068 InvalidFileDescriptor ,
7169 /// IO error
7270 Io ( io:: Error ) ,
73- /// JSON decoder error
74- JsonDecoder ( json:: DecoderError ) ,
7571 /// Mustache template error
7672 Mustache ( mustache:: Error ) ,
7773 /// FFI null error
@@ -92,8 +88,6 @@ pub enum Error {
9288 StrFromUtf8 ( str:: Utf8Error ) ,
9389 /// Cast String
9490 StringFromUtf8 ( string:: FromUtf8Error ) ,
95- // ZDaemon error
96- ZDaemon ( zdaemon:: Error ) ,
9791 #[ cfg( feature = "remote-run" ) ]
9892 /// ZFileXfer error
9993 ZFileXfer ( zfilexfer:: Error ) ,
@@ -122,7 +116,6 @@ impl fmt::Display for Error {
122116 Error :: HostResponse => write ! ( f, "Invalid response from host" ) ,
123117 Error :: InvalidFileDescriptor => write ! ( f, "Invalid file descriptor" ) ,
124118 Error :: Io ( ref e) => write ! ( f, "IO error: {}" , e) ,
125- Error :: JsonDecoder ( ref e) => write ! ( f, "JSON decoder error: {}" , e) ,
126119 Error :: Mustache ( ref e) => write ! ( f, "Mustache error: {:?}" , e) ,
127120 Error :: NulError ( ref e) => write ! ( f, "Nul error: {}" , e) ,
128121 Error :: NullPtr ( ref e) => write ! ( f, "Received null when we expected a {} pointer" , e) ,
@@ -133,7 +126,6 @@ impl fmt::Display for Error {
133126 Error :: SerdeJson ( ref e) => write ! ( f, "Serde JSON error: {}" , e) ,
134127 Error :: StrFromUtf8 ( ref e) => write ! ( f, "Convert from UTF8 slice to str error: {}" , e) ,
135128 Error :: StringFromUtf8 ( ref e) => write ! ( f, "Convert from UTF8 slice to String error: {}" , e) ,
136- Error :: ZDaemon ( ref e) => write ! ( f, "ZDaemon error: {}" , e) ,
137129 #[ cfg( feature = "remote-run" ) ]
138130 Error :: ZFileXfer ( ref e) => write ! ( f, "ZFileXfer error: {}" , e) ,
139131 }
@@ -161,7 +153,6 @@ impl error::Error for Error {
161153 Error :: HostResponse => "Invalid response from host" ,
162154 Error :: InvalidFileDescriptor => "Invalid file descriptor" ,
163155 Error :: Io ( ref e) => e. description ( ) ,
164- Error :: JsonDecoder ( ref e) => e. description ( ) ,
165156 Error :: Mustache ( ref e) => e. description ( ) ,
166157 Error :: NulError ( ref e) => e. description ( ) ,
167158 Error :: NullPtr ( ref e) => e,
@@ -172,7 +163,6 @@ impl error::Error for Error {
172163 Error :: SerdeJson ( ref e) => e. description ( ) ,
173164 Error :: StrFromUtf8 ( ref e) => e. description ( ) ,
174165 Error :: StringFromUtf8 ( ref e) => e. description ( ) ,
175- Error :: ZDaemon ( ref e) => e. description ( ) ,
176166 #[ cfg( feature = "remote-run" ) ]
177167 Error :: ZFileXfer ( ref e) => e. description ( ) ,
178168 }
@@ -211,12 +201,6 @@ impl convert::From<io::Error> for Error {
211201 }
212202}
213203
214- impl convert:: From < json:: DecoderError > for Error {
215- fn from ( err : json:: DecoderError ) -> Error {
216- Error :: JsonDecoder ( err)
217- }
218- }
219-
220204#[ cfg( feature = "remote-run" ) ]
221205impl convert:: From < MissingFrame > for Error {
222206 fn from ( err : MissingFrame ) -> Error {
@@ -266,12 +250,6 @@ impl convert::From<num::ParseIntError> for Error {
266250 }
267251}
268252
269- impl convert:: From < zdaemon:: Error > for Error {
270- fn from ( err : zdaemon:: Error ) -> Error {
271- Error :: ZDaemon ( err)
272- }
273- }
274-
275253#[ cfg( feature = "remote-run" ) ]
276254impl convert:: From < zfilexfer:: Error > for Error {
277255 fn from ( err : zfilexfer:: Error ) -> Error {
0 commit comments