[asterisk-scf-commits] asterisk-scf/release/media_rtp_pjmedia.git branch "master" updated.
Commits to the Asterisk SCF project code repositories
asterisk-scf-commits at lists.digium.com
Wed Mar 2 13:56:09 CST 2011
branch "master" has been updated
via b87be842f83fc697fdc7e7c7d2775f2607af7ce6 (commit)
from 13bea3f9271b2ecbe159b74cc0d8295819a6fd0b (commit)
Summary of changes:
src/RtpStateReplicatorListener.cpp | 6 ++++--
test/TestRTPpjmedia.cpp | 6 ++++--
2 files changed, 8 insertions(+), 4 deletions(-)
- Log -----------------------------------------------------------------
commit b87be842f83fc697fdc7e7c7d2775f2607af7ce6
Author: Joshua Colp <jcolp at digium.com>
Date: Wed Mar 2 15:56:46 2011 -0400
Visitors must be allocated on the heap and not the stack to ensure Ice object reference counting works properly.
diff --git a/src/RtpStateReplicatorListener.cpp b/src/RtpStateReplicatorListener.cpp
index fb0061e..cc00a2a 100644
--- a/src/RtpStateReplicatorListener.cpp
+++ b/src/RtpStateReplicatorListener.cpp
@@ -124,11 +124,13 @@ public:
i->second->getSession()->getSource()->setSink(item->mSink, Ice::Current());
}
}
- } v(this);
+ };
+
+ AsteriskSCF::Media::RTP::V1::RtpStateItemVisitorPtr v = new visitor(this);
for (RtpStateItemSeq::const_iterator item = items.begin(); item != items.end(); ++item)
{
- (*item)->visit(&v);
+ (*item)->visit(v);
}
}
diff --git a/test/TestRTPpjmedia.cpp b/test/TestRTPpjmedia.cpp
index 3b7cb2a..f03cb72 100644
--- a/test/TestRTPpjmedia.cpp
+++ b/test/TestRTPpjmedia.cpp
@@ -178,11 +178,13 @@ void TestRtpReplicatorListener::stateSet(const RtpStateItemSeq& items, const Ice
boost::mutex::scoped_lock lock(Testbed.mLock);
Testbed.mCondition.notify_one();
}
- } v(this);
+ };
+
+ AsteriskSCF::Media::RTP::V1::RtpStateItemVisitorPtr v = new visitor(this);
for (RtpStateItemSeq::const_iterator item = items.begin(); item != items.end(); ++item)
{
- (*item)->visit(&v);
+ (*item)->visit(v);
}
}
-----------------------------------------------------------------------
--
asterisk-scf/release/media_rtp_pjmedia.git
More information about the asterisk-scf-commits
mailing list