#include "portab.h"
-static char UNUSED id[] = "$Id: irc-mode.c,v 1.30 2003/01/17 19:04:19 alex Exp $";
+static char UNUSED id[] = "$Id: irc-mode.c,v 1.32 2003/11/05 23:24:48 alex Exp $";
#include "imp.h"
#include <assert.h>
}
Log( LOG_DEBUG, "User \"%s\": Mode change, now \"%s\".", Client_Mask( Target ), Client_Modes( Target ));
}
-
+
+ IRC_SetPenalty( Client, 1 );
return ok;
} /* Client_Mode */
/* Is there a valid mode change? */
if( ! x[0] ) continue;
+ /* Validate target client */
+ if( client && ( ! Channel_IsMemberOf( Channel, client )))
+ {
+ if( ! IRC_WriteStrClient( Origin, ERR_USERNOTINCHANNEL_MSG, Client_ID( Origin ), Client_ID( client ), Channel_Name( Channel ))) break;
+ continue;
+ }
+
if( set )
{
/* Set mode */
}
}
+ IRC_SetPenalty( Client, 1 );
return CONNECTED;
} /* Channel_Mode */