mirror of
git://git.psyced.org/git/psyced
synced 2024-08-15 03:25:10 +00:00
upgrade gammas
This commit is contained in:
parent
ac39429f4a
commit
a602585399
20 changed files with 20 additions and 156 deletions
|
@ -119,7 +119,7 @@ int msg(string source, string mc, string data,
|
|||
#else
|
||||
unless(vars["_language"]) vars["_language"] = "en";
|
||||
#endif
|
||||
#ifndef GAMMA // TODO: decide if this is good or bad
|
||||
#if 0
|
||||
else if (abbrev("_status_person_absent", mc)) {
|
||||
PT(("Intercepted absent from %O to %O\n", mc, source, ME))
|
||||
return 1;
|
||||
|
|
|
@ -56,12 +56,10 @@ quit() {
|
|||
disconnected(remainder) {
|
||||
// TODO: handle remainder
|
||||
P2(( "gateway %O disconnected\n", ME ))
|
||||
#ifdef GAMMA
|
||||
// sometimes we get complete presence packets in the socket close
|
||||
// remainder. probably broken xmpp implementations, let's try and
|
||||
// do the best we can with it by forwarding stuff to feed().
|
||||
if (remainder && strlen(remainder)) feed(remainder);
|
||||
#endif
|
||||
if (objectp(active)) active -> removeGateway(streamid);
|
||||
#ifdef _flag_log_sockets_XMPP
|
||||
log_file("RAW_XMPP", "\n%O disc\t%O", ME, ctime());
|
||||
|
|
|
@ -298,7 +298,6 @@ jabberMsg(XMLNode node, mixed origin, mixed *su, array(mixed) tu) {
|
|||
} else {
|
||||
// no relaying allowed, so we ignore hostname
|
||||
o = summon_person(tu[UUser]);
|
||||
#ifdef GAMMA
|
||||
// xep 0085 typing notices - we even split active into a separate message
|
||||
// for now. could be sent as a flag
|
||||
if ((node[t="/composing"] || node[t="/active"] ||
|
||||
|
@ -307,7 +306,6 @@ jabberMsg(XMLNode node, mixed origin, mixed *su, array(mixed) tu) {
|
|||
// ...
|
||||
sendmsg(o, "_notice_typing_" + t[1..], 0, vars);
|
||||
}
|
||||
#endif
|
||||
// there are some messages which dont have a body
|
||||
// we dont care about those
|
||||
unless (node["/body"]) return;
|
||||
|
@ -384,9 +382,6 @@ jabberMsg(XMLNode node, mixed origin, mixed *su, array(mixed) tu) {
|
|||
// so there wont be circular error messages
|
||||
if (tu[UUser]) {
|
||||
o = summon_person(tu[UUser]);
|
||||
#ifndef GAMMA
|
||||
if (o && o->execute_callback(node["@id"], ({ vars["_INTERNAL_identification"], vars, node }))) return 1;
|
||||
#else
|
||||
// the following should catch errors - in theory, requires testing
|
||||
if (o) {
|
||||
int cb_ret;
|
||||
|
@ -401,7 +396,6 @@ jabberMsg(XMLNode node, mixed origin, mixed *su, array(mixed) tu) {
|
|||
return 1;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
if (tu[UResource]) {
|
||||
// innerxml
|
||||
|
|
|
@ -115,14 +115,12 @@ userLogon() {
|
|||
return ::userLogon();
|
||||
}
|
||||
|
||||
#ifdef GAMMA
|
||||
authChecked(result, varargs array(mixed) args) {
|
||||
// a point where we could be sending our jabber:iq:auth reply
|
||||
// instead of letting _notice_login do that
|
||||
PT(("%O got authChecked %O, %O\n", ME, result, args))
|
||||
return ::authChecked(result, args...);
|
||||
}
|
||||
#endif
|
||||
|
||||
jabberMsg(XMLNode node) {
|
||||
XMLNode helper;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue