mirror of
https://github.com/ceph/ceph
synced 2024-12-17 17:05:42 +00:00
msgr: allow users to mark_down a NULL Connection*
Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Sam Just <sam.just@inktank.com>
This commit is contained in:
parent
f8682cb8a7
commit
4f8ba0e775
@ -476,6 +476,7 @@ public:
|
||||
* discard its outgoing queue, and if the endpoint tries
|
||||
* to reconnect they will discard their queue when we
|
||||
* inform them of the session reset.
|
||||
* If the Connection* is NULL, this is a no-op.
|
||||
* It does not generate any notifications to the Dispatcher.
|
||||
*
|
||||
* @param con The Connection to mark down.
|
||||
|
@ -585,6 +585,8 @@ void SimpleMessenger::mark_down(const entity_addr_t& addr)
|
||||
|
||||
void SimpleMessenger::mark_down(Connection *con)
|
||||
{
|
||||
if (con == NULL)
|
||||
return;
|
||||
lock.Lock();
|
||||
Pipe *p = static_cast<Pipe *>(con->get_pipe());
|
||||
if (p) {
|
||||
|
Loading…
Reference in New Issue
Block a user