From 971e42d7ce8981ef145e02dc99bbcb6d0559eebf Mon Sep 17 00:00:00 2001 From: rhn Date: Sun, 29 Apr 2018 15:45:02 +0200 Subject: Add Message::header --- src/error.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/error.rs') diff --git a/src/error.rs b/src/error.rs index b1e5cdc..6434ee3 100644 --- a/src/error.rs +++ b/src/error.rs @@ -14,6 +14,7 @@ pub type Result = result::Result; pub enum Error { IoError(io::Error), NotmuchError(ffi::Status), + UnspecifiedError, } impl fmt::Display for Error { @@ -27,6 +28,7 @@ impl std::error::Error for Error { match *self { Error::IoError(ref e) => error::Error::description(e), Error::NotmuchError(ref e) => e.description(), + Error::UnspecifiedError => "Generic notmuch error", } } @@ -34,6 +36,7 @@ impl std::error::Error for Error { match *self { Error::IoError(ref e) => Some(e), Error::NotmuchError(ref e) => Some(e), + Error::UnspecifiedError => None } } } -- cgit v1.2.1