From: Haomai Wang Date: Wed, 11 Feb 2015 14:40:51 +0000 (+0800) Subject: AsyncConnection: Clean up unused variables X-Git-Tag: suse_latest~36^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=956d8e7a70bfe4a70bcb57f4e2e1981487a49c52;p=ceph.git AsyncConnection: Clean up unused variables Signed-off-by: Haomai Wang --- diff --git a/src/msg/async/AsyncConnection.cc b/src/msg/async/AsyncConnection.cc index cfef223e03b5..aed8c10ed691 100644 --- a/src/msg/async/AsyncConnection.cc +++ b/src/msg/async/AsyncConnection.cc @@ -179,8 +179,7 @@ AsyncConnection::AsyncConnection(CephContext *cct, AsyncMessenger *m, EventCente out_seq(0), in_seq(0), in_seq_acked(0), state(STATE_NONE), state_after_send(0), sd(-1), port(-1), lock("AsyncConnection::lock"), open_write(false), keepalive(false), recv_buf(NULL), recv_max_prefetch(MIN(msgr->cct->_conf->ms_tcp_prefetch_max_size, TCP_PREFETCH_MIN_SIZE)), - recv_start(0), recv_end(0), stop_lock("AsyncConnection::stop_lock"), - got_bad_auth(false), authorizer(NULL), replacing(false), + recv_start(0), recv_end(0), got_bad_auth(false), authorizer(NULL), replacing(false), is_reset_from_peer(false), once_ready(false), state_buffer(NULL), state_offset(0), net(cct), center(c) { read_handler.reset(new C_handle_read(this)); @@ -2023,12 +2022,12 @@ void AsyncConnection::fault() replacing = false; outcoming_bl.clear(); if (!once_ready && !is_queued() && - state >=STATE_ACCEPTING && state <= STATE_ACCEPTING_WAIT_CONNECT_MSG_AUTH) { - ldout(async_msgr->cct, 0) << __func__ << " with nothing to send and in the half " - << "accept state just closed, state=" - << get_state_name(state) << dendl; - _stop(); - return ; + state >=STATE_ACCEPTING && state <= STATE_ACCEPTING_WAIT_CONNECT_MSG_AUTH) { + ldout(async_msgr->cct, 0) << __func__ << " with nothing to send and in the half " + << "accept state just closed, state=" + << get_state_name(state) << dendl; + _stop(); + return ; } if (policy.standby && !is_queued()) { ldout(async_msgr->cct,0) << __func__ << " with nothing to send, going to standby" << dendl; diff --git a/src/msg/async/AsyncConnection.h b/src/msg/async/AsyncConnection.h index d511b8e8a3ac..da2aad1e4f4f 100644 --- a/src/msg/async/AsyncConnection.h +++ b/src/msg/async/AsyncConnection.h @@ -225,11 +225,7 @@ class AsyncConnection : public Connection { EventCallbackRef reset_handler; EventCallbackRef remote_reset_handler; EventCallbackRef connect_handler; - EventCallbackRef fast_connect_handler; EventCallbackRef accept_handler; - EventCallbackRef fast_accept_handler; - EventCallbackRef stop_handler; - EventCallbackRef signal_handler; EventCallbackRef local_deliver_handler; bool keepalive; struct iovec msgvec[IOV_MAX]; @@ -237,8 +233,6 @@ class AsyncConnection : public Connection { uint32_t recv_max_prefetch; uint32_t recv_start; uint32_t recv_end; - Mutex stop_lock; // used to protect `mark_down_cond` - Cond stop_cond; set register_time_events; // need to delete it if stop // Tis section are temp variables used by state transition @@ -265,7 +259,6 @@ class AsyncConnection : public Connection { // there won't exists conflicting connection so we use // "replacing" to skip RESETSESSION to avoid detect wrong // presentation - bool allow_session_reset; bool is_reset_from_peer; bool once_ready; atomic_t stopping;