Updated Branches: refs/heads/master 9ce0e7189 -> 8e2f2090f
TS-1241 Memory leaks when using TSHttpSchedule(). Author: Aidan McGurn Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/8e2f2090 Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/8e2f2090 Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/8e2f2090 Branch: refs/heads/master Commit: 8e2f2090ff81819eeb8f9196768cac1e22060b42 Parents: 9ce0e71 Author: Aidan McGurn <[email protected]> Authored: Wed May 2 15:08:07 2012 -0600 Committer: Leif Hedstrom <[email protected]> Committed: Wed May 2 15:08:07 2012 -0600 ---------------------------------------------------------------------- proxy/InkAPI.cc | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/trafficserver/blob/8e2f2090/proxy/InkAPI.cc ---------------------------------------------------------------------- diff --git a/proxy/InkAPI.cc b/proxy/InkAPI.cc index 2453550..03f6cbe 100644 --- a/proxy/InkAPI.cc +++ b/proxy/InkAPI.cc @@ -4372,6 +4372,11 @@ TSHttpSchedule(TSCont contp, TSHttpTxn txnp, ink_hrtime timeout) FORCE_PLUGIN_MUTEX(contp); + INKContInternal *i = (INKContInternal *) contp; + + if (ink_atomic_increment((int *) &i->m_event_count, 1) < 0) + ink_assert (!"not reached"); + TSAction action; Continuation *cont = (Continuation*)contp; HttpSM *sm = (HttpSM*)txnp;
