Now set param replaces the whole object.

git-svn-id: http://yate.null.ro/svn/yate/trunk@1644 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
marian 2008-01-17 15:40:47 +00:00
parent 56d50b5c5d
commit 97086f1ede
1 changed files with 5 additions and 5 deletions

View File

@ -66,11 +66,11 @@ NamedList& NamedList::setParam(NamedString* param)
{
XDebug(DebugInfo,"NamedList::setParam(%p) [\"%s\",\"%s\"]",
param,param->name().c_str(),param->c_str());
NamedString *s = getParam(param->name());
if (s) {
*s = param->c_str();
param->destruct();
}
if (!param)
return *this;
ObjList* p = m_params.find(param->name());
if (p)
p->set(param);
else
m_params.append(param);
return *this;