From: Vu Pham Date: Wed, 15 Jul 2015 23:20:00 +0000 (-0700) Subject: xio: safely clean up transport messages with valid connection X-Git-Tag: v9.1.0~482^2~3 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=1c5cef75f71f4ec714b74af0644c4028bb1e2840;p=ceph.git xio: safely clean up transport messages with valid connection Transport messages can be safely and completely cleaned up as long as low level connection is valid Signed-off-by: Vu Pham --- diff --git a/src/msg/xio/XioPortal.h b/src/msg/xio/XioPortal.h index a32b2e299ca3..cb711c66d24c 100644 --- a/src/msg/xio/XioPortal.h +++ b/src/msg/xio/XioPortal.h @@ -159,7 +159,7 @@ public: struct xio_msg *msg = xrsp->dequeue(); struct xio_msg *next_msg = NULL; int code; - if (unlikely(!xrsp->xcon->conn || !xrsp->xcon->is_connected())) { + if (unlikely(!xrsp->xcon->conn)) { // NOTE: msg is not safe to dereference if the connection was torn down xrsp->xcon->msg_release_fail(msg, ENOTCONN); }