Change the error to "offline" only if we positively know the user exists and it's not registered.

git-svn-id: http://yate.null.ro/svn/yate/trunk@3510 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2010-08-25 13:08:09 +00:00
parent 04385930d0
commit 022cf4ca04
1 changed files with 3 additions and 2 deletions

View File

@ -215,8 +215,10 @@ bool RouteHandler::received(Message &msg)
while (true) {
String data;
if (!ac) {
if (s_cfg.getSection(username))
if (s_cfg.getSection(username)) {
msg.setParam("error","offline");
break;
}
ObjList* o = s_expand.find(username);
if (!o)
break;
@ -248,7 +250,6 @@ bool RouteHandler::received(Message &msg)
Debug("RegFile",DebugInfo,"Routed '%s' via '%s'",username.c_str(),data.c_str());
return true;
}
msg.setParam("error","offline");
return false;
}