Re: [reSIProcate-users] MessageDecorator::clone function of 1.4
So my code is correctly, right ?
On Tue, Oct 28, 2008 at 6:20 AM, Byron Campen
<bcampen@xxxxxxxxxxxx> wrote:
The caller takes ownership when it calls clone.
Best regards,
Byron Campen
The 1.4 has added a member function which named clone for class MessageDecorator, this is a
pure virtual function and requires implement it in derivation class.
I have been wrote this function as below:
MessageDecorator* SipMessageDecorator::clone() const
{
SipMessageDecorator * decorator = new SipMessageDecorator;
decorator->setStunResult(mStunIP, mStunPort);
return (MessageDecorator *)decorator;
}
So far with my testing it's working fine, but does there has memeory leak with "SipMessageDecorator * decorator = new SipMessageDecorator;" ?
Please advice, thanks.
_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/