Repository: trafficserver Updated Branches: refs/heads/master 208e5385a -> 59da9685d
TS-3889 Avoid reenabling the txn before we release the mbuf Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/59da9685 Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/59da9685 Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/59da9685 Branch: refs/heads/master Commit: 59da9685d5e494dae6a348540ca4e6541ac285c3 Parents: 208e538 Author: Leif Hedstrom <[email protected]> Authored: Thu Sep 3 12:25:06 2015 -0600 Committer: Leif Hedstrom <[email protected]> Committed: Thu Sep 3 12:25:11 2015 -0600 ---------------------------------------------------------------------- plugins/experimental/authproxy/authproxy.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/trafficserver/blob/59da9685/plugins/experimental/authproxy/authproxy.cc ---------------------------------------------------------------------- diff --git a/plugins/experimental/authproxy/authproxy.cc b/plugins/experimental/authproxy/authproxy.cc index e734b7a..0eb6f39 100644 --- a/plugins/experimental/authproxy/authproxy.cc +++ b/plugins/experimental/authproxy/authproxy.cc @@ -470,7 +470,8 @@ StateAuthProxySendResponse(AuthRequestContext *auth, void * /* edata ATS_UNUSED TSReleaseAssert(TSHttpHdrCopy(mbuf, mhdr, auth->rheader.buffer, auth->rheader.header) == TS_SUCCESS); - status = TSHttpHdrStatusGet(mbuf, mhdr), snprintf(msg, sizeof(msg), "%d %s\n", status, TSHttpHdrReasonLookup(status)); + status = TSHttpHdrStatusGet(mbuf, mhdr); + snprintf(msg, sizeof(msg), "%d %s\n", status, TSHttpHdrReasonLookup(status)); TSHttpTxnErrorBodySet(auth->txn, TSstrdup(msg), strlen(msg), TSstrdup("text/plain")); @@ -483,8 +484,9 @@ StateAuthProxySendResponse(AuthRequestContext *auth, void * /* edata ATS_UNUSED AuthLogDebug("sending auth proxy response for status %d", status); - TSHttpTxnReenable(auth->txn, TS_EVENT_HTTP_CONTINUE); TSHandleMLocRelease(mbuf, TS_NULL_MLOC, mhdr); + TSHttpTxnReenable(auth->txn, TS_EVENT_HTTP_CONTINUE); + return TS_EVENT_CONTINUE; }
