imap/connection.rs: debug print NO/BAD responses
parent
fda947f8fb
commit
d827ea1001
|
@ -440,13 +440,23 @@ impl ImapConnection {
|
||||||
match self.server_conf.protocol {
|
match self.server_conf.protocol {
|
||||||
ImapProtocol::IMAP => {
|
ImapProtocol::IMAP => {
|
||||||
let r: ImapResponse = ImapResponse::from(&response);
|
let r: ImapResponse = ImapResponse::from(&response);
|
||||||
if let ImapResponse::Bye(ref response_code) = r {
|
match r {
|
||||||
|
ImapResponse::Bye(ref response_code) => {
|
||||||
self.stream = Err(MeliError::new(format!(
|
self.stream = Err(MeliError::new(format!(
|
||||||
"Offline: received BYE: {:?}",
|
"Offline: received BYE: {:?}",
|
||||||
response_code
|
response_code
|
||||||
)));
|
)));
|
||||||
ret.push_str(&response);
|
ret.push_str(&response);
|
||||||
} else {
|
}
|
||||||
|
ImapResponse::No(ref response_code) => {
|
||||||
|
debug!("Received NO response: {:?} {:?}", response_code, response);
|
||||||
|
ret.push_str(&response);
|
||||||
|
}
|
||||||
|
ImapResponse::Bad(ref response_code) => {
|
||||||
|
debug!("Received BAD response: {:?} {:?}", response_code, response);
|
||||||
|
ret.push_str(&response);
|
||||||
|
}
|
||||||
|
_ => {
|
||||||
/*debug!(
|
/*debug!(
|
||||||
"check every line for required_responses: {:#?}",
|
"check every line for required_responses: {:#?}",
|
||||||
&required_responses
|
&required_responses
|
||||||
|
@ -459,6 +469,7 @@ impl ImapConnection {
|
||||||
}
|
}
|
||||||
//ret.push_str(&response);
|
//ret.push_str(&response);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
r.into()
|
r.into()
|
||||||
}
|
}
|
||||||
ImapProtocol::ManageSieve => {
|
ImapProtocol::ManageSieve => {
|
||||||
|
|
Loading…
Reference in New Issue