You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by jp...@apache.org on 2016/05/11 20:31:54 UTC
[trafficserver] 30/33: TS-4425: Switch the remainder of proxy/ over
to Ptr::get().
This is an automated email from the ASF dual-hosted git repository.
jpeach pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/trafficserver.git
commit a95fdf3b67f2715d7a213523de8efbd7150f3a7e
Author: James Peach <jp...@apache.org>
AuthorDate: Sat May 7 14:05:50 2016 -0700
TS-4425: Switch the remainder of proxy/ over to Ptr::get().
---
proxy/CacheControl.cc | 2 +-
proxy/CoreUtils.cc | 4 ++--
proxy/CoreUtils.h | 2 ++
proxy/FetchSM.cc | 16 +++++++++-------
proxy/ICP.cc | 20 ++++++++++----------
proxy/ICP.h | 10 +++++-----
proxy/ICPConfig.cc | 4 ++--
proxy/InkAPI.cc | 16 +++++++++++-----
proxy/InkAPIInternal.h | 2 +-
proxy/PluginVC.cc | 4 ++--
proxy/ReverseProxy.cc | 2 +-
proxy/SocksProxy.cc | 2 +-
proxy/Transform.cc | 2 +-
proxy/congest/MT_hashtable.h | 3 ++-
proxy/http/HttpCacheSM.h | 2 +-
proxy/http/HttpProxyServerMain.cc | 5 ++---
proxy/http/HttpSM.cc | 8 ++++----
proxy/http/HttpSessionManager.cc | 4 ++--
proxy/http/HttpTunnel.cc | 2 +-
proxy/http/HttpTunnel.h | 2 +-
proxy/http2/Http2ClientSession.h | 2 +-
21 files changed, 62 insertions(+), 52 deletions(-)
diff --git a/proxy/CacheControl.cc b/proxy/CacheControl.cc
index d344979..5f95c70 100644
--- a/proxy/CacheControl.cc
+++ b/proxy/CacheControl.cc
@@ -99,7 +99,7 @@ struct CC_UpdateContinuation : public Continuation {
delete this;
return EVENT_DONE;
}
- CC_UpdateContinuation(ProxyMutex *m) : Continuation(m) { SET_HANDLER(&CC_UpdateContinuation::file_update_handler); }
+ CC_UpdateContinuation(Ptr<ProxyMutex> &m) : Continuation(m) { SET_HANDLER(&CC_UpdateContinuation::file_update_handler); }
};
int
diff --git a/proxy/CoreUtils.cc b/proxy/CoreUtils.cc
index 3267bb7..8724d28 100644
--- a/proxy/CoreUtils.cc
+++ b/proxy/CoreUtils.cc
@@ -743,8 +743,8 @@ CoreUtils::process_EThread(EThread *eth_test)
ats_free(buf);
}
-static void
-print_netstate(NetState *n)
+void
+CoreUtils::print_netstate(NetState *n)
{
printf(" enabled: %d\n", n->enabled);
printf(" op: %d _cont: 0x%p\n", n->vio.op, n->vio._cont);
diff --git a/proxy/CoreUtils.h b/proxy/CoreUtils.h
index b9987b8..cd7e0da 100644
--- a/proxy/CoreUtils.h
+++ b/proxy/CoreUtils.h
@@ -92,6 +92,7 @@ class HdrHeap;
class EThread;
class UnixNetVConnection;
+struct NetState;
class CoreUtils
{
@@ -185,6 +186,7 @@ public:
* outputs: none
**********************************************************************/
static void print_http_hdr(HTTPHdr *h, const char *name);
+ static void print_netstate(NetState *n);
/**********************************************************************
* purpose: loads a null terminated string from the core file
diff --git a/proxy/FetchSM.cc b/proxy/FetchSM.cc
index 1a94b39..2c35049 100644
--- a/proxy/FetchSM.cc
+++ b/proxy/FetchSM.cc
@@ -343,12 +343,10 @@ out:
}
void
-FetchSM::get_info_from_buffer(IOBufferReader *the_reader)
+FetchSM::get_info_from_buffer(IOBufferReader *reader)
{
char *buf, *info;
int64_t read_avail, read_done;
- IOBufferBlock *blk;
- IOBufferReader *reader = the_reader;
if (!reader) {
client_bytes = 0;
@@ -369,9 +367,11 @@ FetchSM::get_info_from_buffer(IOBufferReader *the_reader)
if (!(fetch_flags & TS_FETCH_FLAGS_STREAM) || !check_chunked()) {
/* Read the data out of the reader */
while (read_avail > 0) {
- if (reader->block != NULL)
+ if (reader->block) {
reader->skip_empty_blocks();
- blk = reader->block;
+ }
+
+ IOBufferBlock *blk = reader->block.get();
// This is the equivalent of TSIOBufferBlockReadStart()
buf = blk->start() + reader->start_offset;
@@ -401,9 +401,11 @@ FetchSM::get_info_from_buffer(IOBufferReader *the_reader)
/* Read the data out of the reader */
read_avail = reader->read_avail();
while (read_avail > 0) {
- if (reader->block != NULL)
+ if (reader->block) {
reader->skip_empty_blocks();
- blk = reader->block;
+ }
+
+ IOBufferBlock *blk = reader->block.get();
// This is the equivalent of TSIOBufferBlockReadStart()
buf = blk->start() + reader->start_offset;
diff --git a/proxy/ICP.cc b/proxy/ICP.cc
index 5442331..3a48cb3 100644
--- a/proxy/ICP.cc
+++ b/proxy/ICP.cc
@@ -526,7 +526,7 @@ ICPPeerReadCont::PeerReadStateMachine(PeerReadData *s, Event *e)
if (!_ICPpr->Lock())
return EVENT_CONT; // unable to get lock, try again later
- bool valid_peer = (_ICPpr->IdToPeer(s->_peer->GetPeerID()) == s->_peer);
+ bool valid_peer = (_ICPpr->IdToPeer(s->_peer->GetPeerID()) == s->_peer.get());
if (valid_peer && _ICPpr->AllowICPQueries() && _ICPpr->GetConfig()->globalConfig()->ICPconfigured()) {
// Note pending incoming ICP request or response
@@ -553,7 +553,7 @@ ICPPeerReadCont::PeerReadStateMachine(PeerReadData *s, Event *e)
// Assumption of one outstanding read per peer...
// Setup read from FD
- ink_assert(s->_peer->buf == NULL);
+ ink_assert(!s->_peer->buf);
Ptr<IOBufferBlock> buf = s->_peer->buf = new_IOBufferBlock();
buf->alloc(ICPHandlerCont::ICPDataBuf_IOBuffer_sizeindex);
s->_peer->fromaddrlen = sizeof(s->_peer->fromaddr);
@@ -563,7 +563,8 @@ ICPPeerReadCont::PeerReadStateMachine(PeerReadData *s, Event *e)
s->_next_state = READ_DATA_DONE;
RECORD_ICP_STATE_CHANGE(s, 0, READ_DATA_DONE);
ink_assert(s->_peer->readAction == NULL);
- Action *a = s->_peer->RecvFrom_re(this, this, buf, buf->write_avail() - 1, &s->_peer->fromaddr.sa, &s->_peer->fromaddrlen);
+ Action *a =
+ s->_peer->RecvFrom_re(this, this, buf.get(), buf->write_avail() - 1, &s->_peer->fromaddr.sa, &s->_peer->fromaddrlen);
if (!a) {
a = ACTION_IO_ERROR;
}
@@ -702,7 +703,7 @@ ICPPeerReadCont::PeerReadStateMachine(PeerReadData *s, Event *e)
// we hand off the decoded buffer from the Peer to the PeerReadData
s->_sender = from;
s->_rICPmsg_len = s->_bytesReceived;
- ink_assert(s->_buf == NULL);
+ ink_assert(!s->_buf);
s->_buf = s->_peer->buf;
s->_rICPmsg = (ICPMsg_t *)s->_buf->start();
s->_peer->buf = NULL;
@@ -2044,7 +2045,7 @@ ICPProcessor::SetupListenSockets()
int index;
ip_port_text_buffer ipb, ipb2;
for (index = 0; index < (_nPeerList + 1); ++index) {
- if ((P = _PeerList[index])) {
+ if ((P = _PeerList[index].get())) {
if ((P->GetType() == PEER_PARENT) || (P->GetType() == PEER_SIBLING)) {
ParentSiblingPeer *pPS = (ParentSiblingPeer *)P;
@@ -2078,7 +2079,7 @@ ICPProcessor::SetupListenSockets()
// We funnel all unicast sends and receives through
// the local peer UDP socket.
//
- ParentSiblingPeer *pPS = (ParentSiblingPeer *)((Peer *)_LocalPeer);
+ ParentSiblingPeer *pPS = (ParentSiblingPeer *)(GetLocalPeer());
NetVCOptions options;
options.local_ip.assign(pPS->GetIP());
@@ -2105,9 +2106,8 @@ ICPProcessor::ShutdownListenSockets()
ink_assert(!PendingQuery());
Peer *P;
- int index;
- for (index = 0; index < (_nPeerList + 1); ++index) {
- if ((P = _PeerList[index])) {
+ for (int index = 0; index < (_nPeerList + 1); ++index) {
+ if ((P = IdToPeer(index))) {
if (P->GetType() == PEER_LOCAL) {
ParentSiblingPeer *pPS = (ParentSiblingPeer *)P;
(void)pPS->GetChan()->close();
@@ -2253,7 +2253,7 @@ ICPProcessor::GenericFindListPeer(IpAddr const &ip, uint16_t port, int validList
Peer *P;
port = htons(port);
for (int n = 0; n < validListItems; ++n) {
- if ((P = List[n])) {
+ if ((P = List[n].get())) {
if ((P->GetIP() == ip) && ((port == 0) || (ats_ip_port_cast(P->GetIP()) == port)))
return P;
}
diff --git a/proxy/ICP.h b/proxy/ICP.h
index f90e9f8..5c282e2 100644
--- a/proxy/ICP.h
+++ b/proxy/ICP.h
@@ -818,12 +818,12 @@ public:
inline Peer *
GetLocalPeer()
{
- return _LocalPeer;
+ return _LocalPeer.get();
}
inline Peer *
IdToPeer(int id)
{
- return _PeerList[id];
+ return _PeerList[id].get();
}
inline ICPConfiguration *
GetConfig()
@@ -918,7 +918,7 @@ private:
inline Peer *
GetNthSendPeer(int n, int bias)
{
- return _SendPeerList[(bias + n) % (_nSendPeerList + 1)];
+ return _SendPeerList[(bias + n) % (_nSendPeerList + 1)].get();
}
inline int
@@ -929,7 +929,7 @@ private:
inline Peer *
GetNthRecvPeer(int n, int bias)
{
- return _RecvPeerList[(bias + n) % (_nRecvPeerList + 1)];
+ return _RecvPeerList[(bias + n) % (_nRecvPeerList + 1)].get();
}
inline int
@@ -951,7 +951,7 @@ private:
inline Peer *
GetNthParentPeer(int n, int bias)
{
- return _ParentPeerList[(bias + n) % (_nParentPeerList + 1)];
+ return _ParentPeerList[(bias + n) % (_nParentPeerList + 1)].get();
}
inline int
GetStartingParentPeerBias()
diff --git a/proxy/ICPConfig.cc b/proxy/ICPConfig.cc
index f668ac7..d3f12fa 100644
--- a/proxy/ICPConfig.cc
+++ b/proxy/ICPConfig.cc
@@ -1028,7 +1028,7 @@ Action *
MultiCastPeer::RecvFrom_re(Continuation *cont, void *token, IOBufferBlock * /* bufblock ATS_UNUSED */, int len,
struct sockaddr *from, socklen_t *fromlen)
{
- Action *a = udpNet.recvfrom_re(cont, token, _recv_chan.fd, from, fromlen, buf, len, true, 0);
+ Action *a = udpNet.recvfrom_re(cont, token, _recv_chan.fd, from, fromlen, buf.get(), len, true, 0);
return a;
}
@@ -1431,7 +1431,7 @@ ICPProcessor::DumpICPConfig()
GetConfig()->globalConfig()->ICPReplyToUnknownPeer(), GetConfig()->globalConfig()->ICPDefaultReplyPort());
for (int i = 0; i < (_nPeerList + 1); i++) {
- P = _PeerList[i];
+ P = IdToPeer(i);
id = P->GetPeerID();
type = P->GetType();
const char *str_type;
diff --git a/proxy/InkAPI.cc b/proxy/InkAPI.cc
index 00b544d..e29ad00 100644
--- a/proxy/InkAPI.cc
+++ b/proxy/InkAPI.cc
@@ -646,6 +646,12 @@ sdk_sanity_check_null_ptr(void *ptr)
return TS_SUCCESS;
}
+static TSReturnCode
+sdk_sanity_check_mutex(Ptr<ProxyMutex> &m)
+{
+ return m ? TS_SUCCESS : TS_ERROR;
+}
+
/**
The function checks if the buffer is Modifiable and returns true if
it is modifiable, else returns false.
@@ -4354,7 +4360,7 @@ TSContMutexGet(TSCont contp)
sdk_assert(sdk_sanity_check_iocore_structure(contp) == TS_SUCCESS);
Continuation *c = (Continuation *)contp;
- return (TSMutex)((ProxyMutex *)c->mutex);
+ return (TSMutex)(c->mutex.get());
}
/* HTTP hooks */
@@ -6418,7 +6424,7 @@ TSHttpTxnServerIntercept(TSCont contp, TSHttpTxn txnp)
INKContInternal *i = (INKContInternal *)contp;
// Must have a mutex
- sdk_assert(sdk_sanity_check_null_ptr((void *)i->mutex) == TS_SUCCESS);
+ sdk_assert(sdk_sanity_check_mutex(i->mutex) == TS_SUCCESS);
http_sm->plugin_tunnel_type = HTTP_PLUGIN_AS_SERVER;
http_sm->plugin_tunnel = PluginVCCore::alloc();
@@ -6435,7 +6441,7 @@ TSHttpTxnIntercept(TSCont contp, TSHttpTxn txnp)
INKContInternal *i = (INKContInternal *)contp;
// Must have a mutex
- sdk_assert(sdk_sanity_check_null_ptr((void *)i->mutex) == TS_SUCCESS);
+ sdk_assert(sdk_sanity_check_mutex(i->mutex) == TS_SUCCESS);
http_sm->plugin_tunnel_type = HTTP_PLUGIN_AS_INTERCEPT;
http_sm->plugin_tunnel = PluginVCCore::alloc();
@@ -7536,7 +7542,7 @@ TSAIORead(int fd, off_t offset, char *buf, size_t buffSize, TSCont contp)
pAIO->aiocb.aio_buf = buf;
pAIO->action = pCont;
- pAIO->thread = ((ProxyMutex *)pCont->mutex)->thread_holding;
+ pAIO->thread = pCont->mutex->thread_holding;
if (ink_aio_read(pAIO, 1) == 1)
return TS_SUCCESS;
@@ -7574,7 +7580,7 @@ TSAIOWrite(int fd, off_t offset, char *buf, const size_t bufSize, TSCont contp)
pAIO->aiocb.aio_buf = buf;
pAIO->aiocb.aio_nbytes = bufSize;
pAIO->action = pCont;
- pAIO->thread = ((ProxyMutex *)pCont->mutex)->thread_holding;
+ pAIO->thread = pCont->mutex->thread_holding;
if (ink_aio_write(pAIO, 1) == 1)
return TS_SUCCESS;
diff --git a/proxy/InkAPIInternal.h b/proxy/InkAPIInternal.h
index 9c42436..7908d1f 100644
--- a/proxy/InkAPIInternal.h
+++ b/proxy/InkAPIInternal.h
@@ -307,7 +307,7 @@ public:
int
event_handler(int, void *)
{
- if (m_cont->mutex != NULL) {
+ if (m_cont->mutex) {
MUTEX_TRY_LOCK(trylock, m_cont->mutex, this_ethread());
if (!trylock.is_locked()) {
eventProcessor.schedule_in(this, HRTIME_MSECONDS(10), ET_TASK);
diff --git a/proxy/PluginVC.cc b/proxy/PluginVC.cc
index a0ec05d..7510c59 100644
--- a/proxy/PluginVC.cc
+++ b/proxy/PluginVC.cc
@@ -145,7 +145,7 @@ PluginVC::main_handler(int event, void *data)
return 0;
}
- if (read_side_mutex.m_ptr != read_state.vio.mutex.m_ptr) {
+ if (read_side_mutex != read_state.vio.mutex) {
// It's possible some swapped the mutex on us before
// we were able to grab it
Mutex_unlock(read_side_mutex, my_ethread);
@@ -167,7 +167,7 @@ PluginVC::main_handler(int event, void *data)
return 0;
}
- if (write_side_mutex.m_ptr != write_state.vio.mutex.m_ptr) {
+ if (write_side_mutex != write_state.vio.mutex) {
// It's possible some swapped the mutex on us before
// we were able to grab it
Mutex_unlock(write_side_mutex, my_ethread);
diff --git a/proxy/ReverseProxy.cc b/proxy/ReverseProxy.cc
index 43af4ed..3595f52 100644
--- a/proxy/ReverseProxy.cc
+++ b/proxy/ReverseProxy.cc
@@ -132,7 +132,7 @@ struct UR_UpdateContinuation : public Continuation {
delete this;
return EVENT_DONE;
}
- UR_UpdateContinuation(ProxyMutex *m) : Continuation(m)
+ UR_UpdateContinuation(Ptr<ProxyMutex> &m) : Continuation(m)
{
SET_HANDLER((UR_UpdContHandler)&UR_UpdateContinuation::file_update_handler);
}
diff --git a/proxy/SocksProxy.cc b/proxy/SocksProxy.cc
index 091c1cd..cd283b3 100644
--- a/proxy/SocksProxy.cc
+++ b/proxy/SocksProxy.cc
@@ -347,7 +347,7 @@ SocksProxy::mainEvent(int event, void *data)
OneWayTunnel *s_to_c = OneWayTunnel::OneWayTunnel_alloc();
c_to_s->init(clientVC, serverVC, NULL, clientVIO, reader);
- s_to_c->init(serverVC, clientVC, /*aCont = */ NULL, 0 /*best guess */, c_to_s->mutex);
+ s_to_c->init(serverVC, clientVC, /*aCont = */ NULL, 0 /*best guess */, c_to_s->mutex.get());
OneWayTunnel::SetupTwoWayTunnel(c_to_s, s_to_c);
diff --git a/proxy/Transform.cc b/proxy/Transform.cc
index 86dcb18..6d395c3 100644
--- a/proxy/Transform.cc
+++ b/proxy/Transform.cc
@@ -385,7 +385,7 @@ TransformTerminus::reenable(VIO *vio)
-------------------------------------------------------------------------*/
TransformVConnection::TransformVConnection(Continuation *cont, APIHook *hooks)
- : TransformVCChain(cont->mutex), m_cont(cont), m_terminus(this), m_closed(0)
+ : TransformVCChain(cont->mutex.get()), m_cont(cont), m_terminus(this), m_closed(0)
{
INKVConnInternal *xform;
diff --git a/proxy/congest/MT_hashtable.h b/proxy/congest/MT_hashtable.h
index 12cebb9..62666f6 100644
--- a/proxy/congest/MT_hashtable.h
+++ b/proxy/congest/MT_hashtable.h
@@ -347,10 +347,11 @@ public:
delete hashTables[i];
}
}
+
ProxyMutex *
lock_for_key(key_t key)
{
- return locks[part_num(key)];
+ return locks[part_num(key)].get();
}
int
diff --git a/proxy/http/HttpCacheSM.h b/proxy/http/HttpCacheSM.h
index e5a9a5f..77b349a 100644
--- a/proxy/http/HttpCacheSM.h
+++ b/proxy/http/HttpCacheSM.h
@@ -60,7 +60,7 @@ public:
HttpCacheSM();
void
- init(HttpSM *sm_arg, ProxyMutex *amutex)
+ init(HttpSM *sm_arg, Ptr<ProxyMutex> &amutex)
{
master_sm = sm_arg;
mutex = amutex;
diff --git a/proxy/http/HttpProxyServerMain.cc b/proxy/http/HttpProxyServerMain.cc
index 76c0925..e59cce2 100644
--- a/proxy/http/HttpProxyServerMain.cc
+++ b/proxy/http/HttpProxyServerMain.cc
@@ -266,9 +266,8 @@ init_HttpProxyServer(int n_accept_threads)
plugin_http_transparent_accept = new HttpSessionAccept(ha_opt);
plugin_http_transparent_accept->mutex = new_ProxyMutex();
}
- if (ssl_plugin_mutex == NULL) {
- ssl_plugin_mutex = mutexAllocator.alloc();
- ssl_plugin_mutex->init("SSL Acceptor List");
+ if (!ssl_plugin_mutex) {
+ ssl_plugin_mutex = new_ProxyMutex();
}
// Do the configuration defined ports.
diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc
index 66c684a..1024a66 100644
--- a/proxy/http/HttpSM.cc
+++ b/proxy/http/HttpSM.cc
@@ -2078,7 +2078,7 @@ HttpSM::process_srv_info(HostDBInfo *r)
HostDBRoundRobin *rr = r->rr();
HostDBInfo *srv = NULL;
if (rr) {
- srv = rr->select_best_srv(t_state.dns_info.srv_hostname, &mutex.m_ptr->thread_holding->generator, ink_cluster_time(),
+ srv = rr->select_best_srv(t_state.dns_info.srv_hostname, &mutex->thread_holding->generator, ink_cluster_time(),
(int)t_state.txn_conf->down_server_timeout);
}
if (!srv) {
@@ -4464,7 +4464,7 @@ HttpSM::do_range_setup_if_necessary()
content_type = t_state.cache_info.object_read->response_get()->value_get(MIME_FIELD_CONTENT_TYPE, MIME_LEN_CONTENT_TYPE,
&field_content_type_len);
// create a Range: transform processor for requests of type Range: bytes=1-2,4-5,10-100 (eg. multiple ranges)
- range_trans = transformProcessor.range_transform(mutex, t_state.ranges, t_state.num_range_fields,
+ range_trans = transformProcessor.range_transform(mutex.get(), t_state.ranges, t_state.num_range_fields,
&t_state.hdr_info.transform_response, content_type, field_content_type_len,
t_state.cache_info.object_read->object_size_get());
api_hooks.append(TS_HTTP_RESPONSE_TRANSFORM_HOOK, range_trans);
@@ -5055,7 +5055,7 @@ HttpSM::do_post_transform_open()
ink_assert(post_transform_info.vc == NULL);
if (is_action_tag_set("http_post_nullt")) {
- txn_hook_prepend(TS_HTTP_REQUEST_TRANSFORM_HOOK, transformProcessor.null_transform(mutex));
+ txn_hook_prepend(TS_HTTP_REQUEST_TRANSFORM_HOOK, transformProcessor.null_transform(mutex.get()));
}
post_transform_info.vc = transformProcessor.open(this, api_hooks.get(TS_HTTP_REQUEST_TRANSFORM_HOOK));
@@ -5076,7 +5076,7 @@ HttpSM::do_transform_open()
APIHook *hooks;
if (is_action_tag_set("http_nullt")) {
- txn_hook_prepend(TS_HTTP_RESPONSE_TRANSFORM_HOOK, transformProcessor.null_transform(mutex));
+ txn_hook_prepend(TS_HTTP_RESPONSE_TRANSFORM_HOOK, transformProcessor.null_transform(mutex.get()));
}
hooks = api_hooks.get(TS_HTTP_RESPONSE_TRANSFORM_HOOK);
diff --git a/proxy/http/HttpSessionManager.cc b/proxy/http/HttpSessionManager.cc
index 004beaa..bfc1005 100644
--- a/proxy/http/HttpSessionManager.cc
+++ b/proxy/http/HttpSessionManager.cc
@@ -279,8 +279,8 @@ HttpSessionManager::acquire_session(Continuation * /* cont ATS_UNUSED */, sockad
// Now check to see if we have a connection in our shared connection pool
EThread *ethread = this_ethread();
ProxyMutex *pool_mutex = (TS_SERVER_SESSION_SHARING_POOL_THREAD == sm->t_state.http_config_param->server_session_sharing_pool) ?
- ethread->server_session_pool->mutex :
- m_g_pool->mutex;
+ ethread->server_session_pool->mutex.get() :
+ m_g_pool->mutex.get();
MUTEX_TRY_LOCK(lock, pool_mutex, ethread);
if (lock.is_locked()) {
if (TS_SERVER_SESSION_SHARING_POOL_THREAD == sm->t_state.http_config_param->server_session_sharing_pool) {
diff --git a/proxy/http/HttpTunnel.cc b/proxy/http/HttpTunnel.cc
index adc84ae..222a4a3 100644
--- a/proxy/http/HttpTunnel.cc
+++ b/proxy/http/HttpTunnel.cc
@@ -534,7 +534,7 @@ HttpTunnel::HttpTunnel()
}
void
-HttpTunnel::init(HttpSM *sm_arg, ProxyMutex *amutex)
+HttpTunnel::init(HttpSM *sm_arg, Ptr<ProxyMutex> &amutex)
{
HttpConfigParams *params = sm_arg->t_state.http_config_param;
sm = sm_arg;
diff --git a/proxy/http/HttpTunnel.h b/proxy/http/HttpTunnel.h
index c4fce16..7cc4a0f 100644
--- a/proxy/http/HttpTunnel.h
+++ b/proxy/http/HttpTunnel.h
@@ -300,7 +300,7 @@ class HttpTunnel : public Continuation
public:
HttpTunnel();
- void init(HttpSM *sm_arg, ProxyMutex *amutex);
+ void init(HttpSM *sm_arg, Ptr<ProxyMutex> &amutex);
void reset();
void kill_tunnel();
bool
diff --git a/proxy/http2/Http2ClientSession.h b/proxy/http2/Http2ClientSession.h
index b0ddc69..bfb156f 100644
--- a/proxy/http2/Http2ClientSession.h
+++ b/proxy/http2/Http2ClientSession.h
@@ -124,7 +124,7 @@ public:
xmit(MIOBuffer *iobuffer)
{
if (ioblock) {
- iobuffer->append_block(this->ioblock);
+ iobuffer->append_block(this->ioblock.get());
} else {
iobuffer->write(this->hdr.raw, sizeof(this->hdr.raw));
}
--
To stop receiving notification emails like this one, please contact
"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>.