static void loc_handler_LA(const char *num, char *parv[], signed int parc) {
if(num[0] != '!' || parc < 1) return;
char *fakehost = NULL;
- if (parc > 1 && parv[1] != "0")
+ if (parc > 1 && strcmp(parv[1], "0") != 0) // 0 = no fakehost
fakehost=parv[1];
-
+
if(parc > 2)
auth_loc_reply(&num[3], parv[0], fakehost, &parv[2] , parc - 2);
else if(parc > 1)
joinbuf_flush(&create);
}
} else {
+ if(find_member_link(chptrb, sptr))
+ return; //we have already joined this channel
//first of all check if we may even join this channel
int err2 = 0;
int flags = 0;
err2 = ERR_CHANNELISFULL;
else if ((chptrb->mode.mode & MODE_REGONLY) && !IsAccount(sptr))
err2 = ERR_NEEDREGGEDNICK;
+ else if ((chptrb->mode.mode & MODE_SSLCHAN) && !IsSSL(sptr))
+ err2 = ERR_SSLCHANNEL;
else if (find_ban(sptr, chptrb->banlist))
err2 = ERR_BANNEDFROMCHAN;
else if (*chptrb->mode.key) //Fix this!
struct Client *acptr;
struct Channel *chptr;
if(acptr = findNUser(parv[1])) {
- if(chptr = FindChannel(parv[3]) && chptr->mode.altchan &&
+ if(IsChannelName(parv[3]) && strIsIrcCh(parv[3]) &&
+ (chptr = FindChannel(parv[3])) && chptr->mode.altchan &&
IsChannelName(chptr->mode.altchan) && strIsIrcCh(chptr->mode.altchan)) {
mode_a_check_altchan(acptr,chptr->mode.altchan);
}
- send_reply(acptr, ERR_JOINACCESS, parv[3]);
+ send_reply(acptr, ERR_JOINACCESS, parv[3], feature_str(FEAT_ERR_JOINACCESS));
}
}