continue;
}
- localinvite(chanservnick, rcup->chan->index->channel, sender);
+ localinvite(chanservnick, rcup->chan->index, sender);
}
chanservstdmessage(sender, QM_DONE);
return CMD_ERROR;
if (cip->channel) {
- localinvite(chanservnick, cip->channel, sender);
+ localinvite(chanservnick, cip, sender);
}
chanservstdmessage(sender, QM_DONE);
msg(QM_NOTPROTECTED, "Sorry, your nick $0 is not protected.", "s"),
msg(QM_SAMEAUTH, "$0 is authed as $1. Cannot reclaim nick.", "ss"),
msg(QM_AUTHFAIL, "Username or password incorrect.", ""),
- msg(QM_AUTHOK, "You are now logged in as $0.", "s"),
+ msg(QM_AUTHOK, "You are now logged in as $0.\nRemember: NO-ONE from QuakeNet will ever ask for your password. NEVER send your password to ANYONE except Q@CServe.quakenet.org.", "s"),
msg(QM_NEWACCOUNT, "Account $0 created successfully.\nInformation about how to access and use your new account will be sent to your email address, $1.\nIf you do not see an email soon be sure to check your spam folder.", "ss"),
msg(QM_AUTHNAMEINUSE, "Someone already has the account name $0!\nIf this is your account use AUTH to login, otherwise please change your nick using /NICK and try again.", "s"),
msg(QM_ALREADYONCHAN, "You're already on $0.", "s"),
}
}
-
localsetmodeinit(&changes, rcup->chan->index->channel, chanservnick);
if (*lp & CUMODE_OP) {
if (!IsService(np) && (CUIsDeny(rcup) || (CIsBitch(rcup->chan) && !CUHasOpPriv(rcup))))
} else {
/* Channel exists but user is not joined: invite if they are +j-b */
if (CUIsAutoInvite(rcup) && CUKnown(rcup) && !CUIsBanned(rcup)) {
- localinvite(chanservnick, rcup->chan->index->channel, np);
+ localinvite(chanservnick, rcup->chan->index, np);
}
}
- }
- }
+ } /* if (rcup->chan->index->channel) */ else {
+ /* Channel doesn't currently exist - send invite anyway for +j */
+ if (CUIsAutoInvite(rcup) && CUKnown(rcup) && !CUIsBanned(rcup)) {
+ localinvite(chanservnick, rcup->chan->index, np);
+ }
+ }
+ } /* for */
}
void cs_checknickbans(nick *np) {
if (hchan->flags & H_PASSIVE)
return;
- localinvite(helpmodnick, hchan->real_channel, husr->real_user);
+ localinvite(helpmodnick, hchan->real_channel->index, husr->real_user);
}
static void hmode_set_channel(hchannel *hchan)
#define _BUILDID "" XStringify(BUILDID) ""
#endif
-#define MODULE_VERSION(id) const char *_version(const char **version) { *version=(id[0]=='\0')?NULL:id; return _BUILDID; };
+#define MODULE_VERSION(id) const char *_version(const char **version) { *version=(id[0]=='\0')?NULL:id; return _BUILDID; }
#endif
}
}
-void localinvite(nick *source, channel *cp, nick *target) {
+void localinvite(nick *source, chanindex *cip, nick *target) {
/* Servers can't send invites */
if (!source)
* argument */
if (connected) {
irc_send("%s I %s :%s",longtonumeric(source->numeric,5),
- target->nick, cp->index->name->content);
+ target->nick, cip->name->content);
}
}
void localusermodechange(nick *np, channel *cp, char *modes);
void sendmessagetochannel(nick *source, channel *cp, char *format, ... ) __attribute__ ((format (printf, 3, 4)));
void sendopnoticetochannel(nick *source, channel *cp, char *format, ... ) __attribute__ ((format (printf, 3, 4)));
-void localinvite(nick *source, channel *cp, nick *target);
+void localinvite(nick *source, chanindex *cip, nick *target);
void localsetmodeinit (modechanges *changes, channel *cp, nick *np);
void localdosetmode_nick (modechanges *changes, nick *target, short modes);
if(!cp)
LUA_RETURN(ps, LUA_FAIL);
- localinvite(lua_nick, cp, np);
+ localinvite(lua_nick, cp->index, np);
LUA_RETURN(ps, LUA_OK);
}