mirror of
https://github.com/ChronosX88/psyced.git
synced 2024-11-12 21:41:04 +00:00
a bit cleaner
This commit is contained in:
parent
553d7cb363
commit
958980e2d6
@ -572,15 +572,16 @@ iq(XMLNode node) {
|
|||||||
|
|
||||||
P3(("+++ %O IQ node %O\n", ME, node))
|
P3(("+++ %O IQ node %O\n", ME, node))
|
||||||
iqchild = getiqchild(node);
|
iqchild = getiqchild(node);
|
||||||
unless(iqchild) switch(node["@type"]) {
|
unless (iqchild && mappingp(iqchild)) switch(node["@type"]) {
|
||||||
case "get":
|
case "get":
|
||||||
case "set":
|
case "set":
|
||||||
case "result":
|
case "result":
|
||||||
case "error":
|
case "error":
|
||||||
break;
|
P1(("%O got empty iq %O\n", ME, node))
|
||||||
|
return;
|
||||||
default:
|
default:
|
||||||
P1(("%O got invalid iq %O\n", ME, node))
|
P1(("%O got invalid iq %O\n", ME, node))
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
helper = iqchild;
|
helper = iqchild;
|
||||||
|
|
||||||
|
@ -1011,34 +1011,10 @@ case "_set_password":
|
|||||||
// TODO? add support for integer _service means multiple
|
// TODO? add support for integer _service means multiple
|
||||||
// catch-all clients possible. do we want this?
|
// catch-all clients possible. do we want this?
|
||||||
if (vars["_service"]) {
|
if (vars["_service"]) {
|
||||||
// oh. we let it suggest a *different* location?
|
|
||||||
// interesting. why don't we also do this for clients?
|
|
||||||
// and who is using this code anyway?
|
|
||||||
linkDel(vars["_service"]);
|
linkDel(vars["_service"]);
|
||||||
linkSet(vars["_service"], vars["_location"], source);
|
linkSet(vars["_service"], vars["_location"], source);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
#if 0
|
|
||||||
if (vars["_password"]) {
|
|
||||||
#ifndef VOLATILE
|
|
||||||
// obviously similar code in usercmd:set()
|
|
||||||
if (!v("password") &&
|
|
||||||
(t = legal_password(vars["_password"],
|
|
||||||
MYNICK))) {
|
|
||||||
ME->pr(t[0], t[1]); // TODO
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
// why do we check password here again
|
|
||||||
// if we are just after a checkPassword?
|
|
||||||
// what are we doing here?
|
|
||||||
#endif
|
|
||||||
} else if (ONLINE &&
|
|
||||||
v("locations")[0] != source) {
|
|
||||||
sendmsg(source,
|
|
||||||
"_error_status_person_connected");
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
// this code should also run for _service, but it
|
// this code should also run for _service, but it
|
||||||
// needs a reorg
|
// needs a reorg
|
||||||
t = v("locations")[0];
|
t = v("locations")[0];
|
||||||
@ -1058,7 +1034,6 @@ case "_set_password":
|
|||||||
// now we leave the old client circuit
|
// now we leave the old client circuit
|
||||||
// to die off.. let's hope that's safe
|
// to die off.. let's hope that's safe
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#ifdef _flag_disable_module_trust
|
#ifdef _flag_disable_module_trust
|
||||||
unless(stringp(source)) {
|
unless(stringp(source)) {
|
||||||
m_delete(v("locations"), 0);
|
m_delete(v("locations"), 0);
|
||||||
|
Loading…
Reference in New Issue
Block a user