mirror of
https://github.com/lightningdevkit/rust-lightning.git
synced 2025-02-25 07:17:40 +01:00
Add trace logs for Errs when handling peer messages
This commit is contained in:
parent
4330ae5d4f
commit
7345c0b3ce
1 changed files with 5 additions and 0 deletions
|
@ -308,17 +308,22 @@ impl<Descriptor: SocketDescriptor> PeerManager<Descriptor> {
|
||||||
continue;
|
continue;
|
||||||
},
|
},
|
||||||
msgs::ErrorAction::DisconnectPeer { msg: _ } => {
|
msgs::ErrorAction::DisconnectPeer { msg: _ } => {
|
||||||
|
//TODO: Try to push msg
|
||||||
|
log_trace!(self, "Got Err handling message, disconnecting peer because {}", e.err);
|
||||||
return Err(PeerHandleError{ no_connection_possible: false });
|
return Err(PeerHandleError{ no_connection_possible: false });
|
||||||
},
|
},
|
||||||
msgs::ErrorAction::IgnoreError => {
|
msgs::ErrorAction::IgnoreError => {
|
||||||
|
log_trace!(self, "Got Err handling message, ignoring because {}", e.err);
|
||||||
continue;
|
continue;
|
||||||
},
|
},
|
||||||
msgs::ErrorAction::SendErrorMessage { msg } => {
|
msgs::ErrorAction::SendErrorMessage { msg } => {
|
||||||
|
log_trace!(self, "Got Err handling message, sending Error message because {}", e.err);
|
||||||
encode_and_send_msg!(msg, 17);
|
encode_and_send_msg!(msg, 17);
|
||||||
continue;
|
continue;
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
log_debug!(self, "Got Err handling message, action not yet filled in: {}", e.err);
|
||||||
return Err(PeerHandleError{ no_connection_possible: false });
|
return Err(PeerHandleError{ no_connection_possible: false });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue