fix away message processing
This commit is contained in:
parent
246ef9b987
commit
f566eccca8
4 changed files with 30 additions and 3 deletions
19
Ircu.c
19
Ircu.c
|
@ -666,6 +666,25 @@ m_pass (char *origin, char **argv, int argc, int srv)
|
|||
*/
|
||||
/* R: AB B #chan 1076064445 ABAAA:o */
|
||||
/* R: AB B #c3 1076083205 +tn ABAAH:o */
|
||||
/*
|
||||
* parv[0] = channel name
|
||||
* parv[1] = channel timestamp
|
||||
* The meaning of the following parv[]'s depend on their first character:
|
||||
* If parv[n] starts with a '+':
|
||||
* Net burst, additive modes
|
||||
* parv[n] = <mode>
|
||||
* parv[n+1] = <param> (optional)
|
||||
* parv[n+2] = <param> (optional)
|
||||
* If parv[n] starts with a '%', then n will be parc-1:
|
||||
* parv[n] = %<ban> <ban> <ban> ...
|
||||
* If parv[n] starts with another character:
|
||||
* parv[n] = <nick>[:<mode>],<nick>[:<mode>],...
|
||||
* where <mode> is the channel mode (ov) of nick and all following nicks.
|
||||
*
|
||||
* Example:
|
||||
* "S BURST #channel 87654321 +ntkl key 123 AAA,AAB:o,BAA,BAB:ov :%ban1 ban2"
|
||||
*/
|
||||
|
||||
static char ircd_buf[BUFSIZE];
|
||||
|
||||
static void
|
||||
|
|
4
ircd.c
4
ircd.c
|
@ -405,8 +405,8 @@ splitbuf (char *buf, char ***argv, int colon_special)
|
|||
SET_SEGV_LOCATION();
|
||||
*argv = calloc (sizeof (char *) * argvsize, 1);
|
||||
argc = 0;
|
||||
if (*buf == ':')
|
||||
buf++;
|
||||
/*if (*buf == ':')
|
||||
buf++;*/
|
||||
while (*buf) {
|
||||
if (argc == argvsize) {
|
||||
argvsize += 8;
|
||||
|
|
|
@ -101,6 +101,7 @@ init_services(void)
|
|||
/* Add command list to services bot */
|
||||
bot_ptr = add_neostats_mod_user (s_Services);
|
||||
bot_ptr->flags = me.onlyopers ? BOT_FLAG_ONLY_OPERS : 0;
|
||||
bot_ptr->flags |= BOT_FLAG_DEAF;
|
||||
add_bot_cmd_list(bot_ptr, ns_commands);
|
||||
return NS_SUCCESS;
|
||||
}
|
||||
|
|
9
users.c
9
users.c
|
@ -270,7 +270,11 @@ UserAway (const char *nick, const char *awaymsg)
|
|||
|
||||
u = finduser (nick);
|
||||
if (u) {
|
||||
strlcpy(u->awaymsg, awaymsg, MAXHOST);
|
||||
if (awaymsg) {
|
||||
strlcpy(u->awaymsg, awaymsg, MAXHOST);
|
||||
} else {
|
||||
u->awaymsg[0] = 0;
|
||||
}
|
||||
AddStringToList (&av, u->nick, &ac);
|
||||
if ((u->is_away == 1) && (!awaymsg)) {
|
||||
u->is_away = 0;
|
||||
|
@ -622,6 +626,9 @@ dumpuser (User* u)
|
|||
#else
|
||||
debugtochannel("Flags: 0x%lx Modes: %s (0x%lx)", u->flags, u->modes, u->Umode);
|
||||
#endif
|
||||
if(u->is_away) {
|
||||
debugtochannel("Away: %s ", u->awaymsg);
|
||||
}
|
||||
|
||||
cm = list_first (u->chans);
|
||||
while (cm) {
|
||||
|
|
Reference in a new issue