25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-28 16:34:13 +01:00

* src/mod_irc/mod_irc_connection.erl: Added handling for

jabber:iq:version and jabber:iq:time requests, participant address
now added to presence status

SVN Revision: 130
This commit is contained in:
Alexey Shchepin 2003-08-12 19:23:55 +00:00
parent 6fff6f0b4c
commit 03682829e7
2 changed files with 23 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2003-08-12 Alexey Shchepin <alexey@sevcom.net>
* src/mod_irc/mod_irc_connection.erl: Added handling for
jabber:iq:version and jabber:iq:time requests, participant address
now added to presence status
2003-08-03 Alexey Shchepin <alexey@sevcom.net> 2003-08-03 Alexey Shchepin <alexey@sevcom.net>
* src/mod_privacy.erl: Privacy rules support * src/mod_privacy.erl: Privacy rules support

View File

@ -298,6 +298,20 @@ handle_info({route_chan, Channel, Resource,
From, From,
To, To,
ID, XMLNS, Type, SubEl); ID, XMLNS, Type, SubEl);
{iq, ID, get, ?NS_VERSION = XMLNS, SubEl} ->
Res = io_lib:format("PRIVMSG ~s :\001VERSION\001\r\n",
[Resource]),
?SEND(Res),
Err = jlib:make_error_reply(
El, ?ERR_FEATURE_NOT_IMPLEMENTED),
ejabberd_router:route(To, From, Err);
{iq, ID, get, ?NS_TIME = XMLNS, SubEl} ->
Res = io_lib:format("PRIVMSG ~s :\001TIME\001\r\n",
[Resource]),
?SEND(Res),
Err = jlib:make_error_reply(
El, ?ERR_FEATURE_NOT_IMPLEMENTED),
ejabberd_router:route(To, From, Err);
_ -> _ ->
Err = jlib:make_error_reply( Err = jlib:make_error_reply(
El, ?ERR_FEATURE_NOT_IMPLEMENTED), El, ?ERR_FEATURE_NOT_IMPLEMENTED),
@ -826,7 +840,9 @@ process_join(StateData, Channel, From, String) ->
[{xmlelement, "item", [{xmlelement, "item",
[{"affiliation", "member"}, [{"affiliation", "member"},
{"role", "participant"}], {"role", "participant"}],
[]}]}]}), []}]},
{xmlelement, "status", [],
[{xmlcdata, FromIdent}]}]}),
{ok, Msg, _} = regexp:sub(String, ".*JOIN[^:]*:", ""), {ok, Msg, _} = regexp:sub(String, ".*JOIN[^:]*:", ""),
ejabberd_router:route({lists:concat([Chan, "%", StateData#state.server]), ejabberd_router:route({lists:concat([Chan, "%", StateData#state.server]),
StateData#state.myname, FromUser}, StateData#state.myname, FromUser},