mirror of
https://github.com/anope/anope.git
synced 2026-07-07 07:13:12 +02:00
Added support m_services.c and m_change.c from Hybrid's contrib folder
This commit is contained in:
@@ -17,9 +17,10 @@ Anope Version 1.8 - GIT
|
||||
2/23 F Fixed rejoining our clients if they are kicked on a TS6 IRCd [ #00]
|
||||
3/2 F Fixed showing SENDPASS in HELP to users who can't use it [ #00]
|
||||
3/3 F Fixed opping our clients on ratbox when not using TS6 [ #00]
|
||||
3/4 F Fixed setting a users host in InspIRCd when vhost is turned off [ #00]
|
||||
10/31 A Added support for plexus3's channel mode +z [#1202]
|
||||
2/23 A Added account tracking support to ratbox protocol module [ #00]
|
||||
3/4 F Fixed setting a users host in InspIRCd when vhost is turned off [ #00]
|
||||
3/21 A Added support for Hybrid's m_services and m_change [ #00]
|
||||
|
||||
Anope Version 1.8.5
|
||||
-------------------
|
||||
|
||||
+52
-4
@@ -716,12 +716,14 @@ void hybrid_cmd_topic(char *whosets, char *chan, char *whosetit,
|
||||
|
||||
void hybrid_cmd_vhost_off(User * u)
|
||||
{
|
||||
/* does not support vhosting */
|
||||
if (ircd->vhost)
|
||||
send_cmd(NULL, "ENCAP * CHGHOST %s %s", u->nick, u->host);
|
||||
}
|
||||
|
||||
void hybrid_cmd_vhost_on(char *nick, char *vIdent, char *vhost)
|
||||
{
|
||||
/* does not support vhosting */
|
||||
if (ircd->vhost)
|
||||
send_cmd(NULL, "ENCAP * CHGHOST %s %s", nick, vhost);
|
||||
}
|
||||
|
||||
void hybrid_cmd_unsqline(char *user)
|
||||
@@ -1285,7 +1287,8 @@ void hybrid_cmd_release_svshold(char *nick)
|
||||
/* SVSNICK */
|
||||
void hybrid_cmd_svsnick(char *nick, char *newnick, time_t when)
|
||||
{
|
||||
/* Not Supported by this IRCD */
|
||||
if (ircd->svsnick)
|
||||
send_cmd(NULL, "SVSNICK %s %s", nick, newnick);
|
||||
}
|
||||
|
||||
void hybrid_cmd_guest_nick(char *nick, char *user, char *host, char *real,
|
||||
@@ -1385,7 +1388,7 @@ void hybrid_cmd_swhois(char *source, char *who, char *mask)
|
||||
|
||||
int anope_event_notice(char *source, int ac, char **av)
|
||||
{
|
||||
return MOD_CONT;
|
||||
return hybrid_event_notice(source, ac, av);
|
||||
}
|
||||
|
||||
int anope_event_admin(char *source, int ac, char **av)
|
||||
@@ -1461,6 +1464,47 @@ void hybrid_cmd_ctcp(char *source, char *dest, char *buf)
|
||||
free(s);
|
||||
}
|
||||
|
||||
static int on_server_connect(int argc, char **argv)
|
||||
{
|
||||
Server *s = findserver(servlist, argv[0]);
|
||||
if (s != NULL && s->uplink == me_server && !(s->flags & SERVER_JUPED))
|
||||
{
|
||||
/* Test these commands to see if they exist */
|
||||
send_cmd(s_ChanServ, "SVSNICK %s %s", s_ChanServ, s_ChanServ);
|
||||
send_cmd(s_ChanServ, "ENCAP * CHGHOST %s .", s_ChanServ);
|
||||
}
|
||||
|
||||
return MOD_CONT;
|
||||
}
|
||||
|
||||
int hybrid_event_notice(char *source, int argc, char **argv)
|
||||
{
|
||||
if (argc > 1)
|
||||
{
|
||||
Server *s = findserver(servlist, source);
|
||||
if (s != NULL)
|
||||
{
|
||||
if (!ircd->svsnick && !strcmp(argv[0], s_ChanServ) && strstr(argv[1], "already in use"))
|
||||
{
|
||||
ircd->svsnick = 1;
|
||||
alog("SVSNICK support enabled");
|
||||
}
|
||||
else if (!ircd->vhost && !strcmp(argv[0], s_ChanServ) && !strcmp(argv[1], "Invalid hostname"))
|
||||
{
|
||||
ircd->vhost = 1;
|
||||
ircd->hostservmode = ircd->hostservaliasmode = sstrdup("+o");
|
||||
alog("VHost support enabled");
|
||||
if (s_HostServ)
|
||||
anope_cmd_nick(s_HostServ, desc_HostServ, ircd->hostservmode);
|
||||
if (s_HostServAlias)
|
||||
anope_cmd_nick(s_HostServAlias, desc_HostServAlias, ircd->hostservaliasmode);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return MOD_CONT;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Tell anope which function we want to perform each task inside of anope.
|
||||
@@ -1550,6 +1594,7 @@ void moduleAddAnopeCmds()
|
||||
**/
|
||||
int AnopeInit(int argc, char **argv)
|
||||
{
|
||||
EvtHook *hook;
|
||||
|
||||
moduleAddAuthor("Anope");
|
||||
moduleAddVersion(VERSION_STRING);
|
||||
@@ -1580,5 +1625,8 @@ int AnopeInit(int argc, char **argv)
|
||||
moduleAddAnopeCmds();
|
||||
moduleAddIRCDMsgs();
|
||||
|
||||
hook = createEventHook(EVENT_SERVER_CONNECT, on_server_connect);
|
||||
moduleAddEventHook(hook);
|
||||
|
||||
return MOD_CONT;
|
||||
}
|
||||
|
||||
@@ -114,3 +114,4 @@ int hybrid_flood_mode_check(char *value);
|
||||
void hybrid_cmd_jupe(char *jserver, char *who, char *reason);
|
||||
int hybrid_valid_nick(char *nick);
|
||||
void hybrid_cmd_ctcp(char *source, char *dest, char *buf);
|
||||
int hybrid_event_notice(char *source, int argc, char **argv);
|
||||
|
||||
+2
-1
@@ -8,9 +8,10 @@ VERSION_MAJOR="1"
|
||||
VERSION_MINOR="8"
|
||||
VERSION_PATCH="5"
|
||||
VERSION_EXTRA="-git"
|
||||
VERSION_BUILD="3065"
|
||||
VERSION_BUILD="3066"
|
||||
|
||||
# $Log$ # Changes since 1.8.5 Release
|
||||
#Revision 3066 - Added support m_services.c and m_change.c from Hybrid's contrib folder
|
||||
#Revision 3065 - Change to users masked host instead of the real one after turning vhost off in inspircd.
|
||||
#Revision 3063 - Fixed opping our clients on ratbox when TS6 is not used.
|
||||
#Revision 3062 - Do not show SENDPASS in NickServ and ChanServ help to users who can't use it
|
||||
|
||||
Reference in New Issue
Block a user