]> arthur.barton.de Git - ngircd-alex.git/blobdiff - src/ngircd/channel.h
Debian: require "telnet" or "telnet-ssl" for building
[ngircd-alex.git] / src / ngircd / channel.h
index 030f9109ceff0eb7bbfa42d435ead49740dc29da..d8607a9cb68cf6c27c2428a6e6d4df4d18bceaaa 100644 (file)
@@ -1,20 +1,21 @@
 /*
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2008 by Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2012 Alexander Barton (alex@barton.de) and Contributors.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Channel management (header)
  */
 
-
 #ifndef __channel_h__
 #define __channel_h__
 
+/**
+ * @file
+ * Channel management (header)
+ */
 
 #if defined(__channel_c__) | defined(S_SPLINT_S)
 
@@ -37,6 +38,7 @@ typedef struct _CHANNEL
        char key[CLIENT_PASS_LEN];      /* Channel key ("password", mode "k" ) */
        unsigned long maxusers;         /* Maximum number of members (mode "l") */
        struct list_head list_bans;     /* list head of banned users */
+       struct list_head list_excepts;  /* list head of (ban) exception list */
        struct list_head list_invites;  /* list head of invited users */
        array keyfile;                  /* Name of the channel key file */
 } CHANNEL;
@@ -57,6 +59,7 @@ typedef POINTER CL2CHAN;
 #endif
 
 GLOBAL struct list_head *Channel_GetListBans PARAMS((CHANNEL *c));
+GLOBAL struct list_head *Channel_GetListExcepts PARAMS((CHANNEL *c));
 GLOBAL struct list_head *Channel_GetListInvites PARAMS((CHANNEL *c));
 
 GLOBAL void Channel_Init PARAMS(( void ));
@@ -71,7 +74,7 @@ GLOBAL void Channel_Quit PARAMS(( CLIENT *Client, const char *Reason ));
 GLOBAL void Channel_Kick PARAMS((CLIENT *Peer, CLIENT *Target, CLIENT *Origin,
                                 const char *Name, const char *Reason));
 
-GLOBAL unsigned long Channel_Count PARAMS(( void ));
+GLOBAL unsigned long Channel_CountVisible PARAMS((CLIENT *Client));
 GLOBAL unsigned long Channel_MemberCount PARAMS(( CHANNEL *Chan ));
 GLOBAL int Channel_CountForUser PARAMS(( CLIENT *Client ));
 
@@ -122,10 +125,13 @@ GLOBAL char *Channel_TopicWho PARAMS(( CHANNEL *Chan ));
 GLOBAL unsigned int Channel_CreationTime PARAMS(( CHANNEL *Chan ));
 #endif
 
-GLOBAL bool Channel_AddInvite PARAMS((CHANNEL *c, const char *Mask, bool OnlyOnce ));
-GLOBAL bool Channel_AddBan PARAMS((CHANNEL *c, const char *Mask ));
+GLOBAL bool Channel_AddBan PARAMS((CHANNEL *c, const char *Mask));
+GLOBAL bool Channel_AddExcept PARAMS((CHANNEL *c, const char *Mask));
+GLOBAL bool Channel_AddInvite PARAMS((CHANNEL *c, const char *Mask,
+                                     bool OnlyOnce));
 
 GLOBAL bool Channel_ShowBans PARAMS((CLIENT *client, CHANNEL *c));
+GLOBAL bool Channel_ShowExcepts PARAMS((CLIENT *client, CHANNEL *c));
 GLOBAL bool Channel_ShowInvites PARAMS((CLIENT *client, CHANNEL *c));
 
 GLOBAL void Channel_LogServer PARAMS((const char *msg));
@@ -133,6 +139,10 @@ GLOBAL void Channel_LogServer PARAMS((const char *msg));
 GLOBAL bool Channel_CheckKey PARAMS((CHANNEL *Chan, CLIENT *Client,
                                     const char *Key));
 
+GLOBAL void Channel_CheckAdminRights PARAMS((CHANNEL *Chan, CLIENT *Client,
+                                            CLIENT *Origin, bool *OnChannel,
+                                            bool *AdminOk, bool *UseServerMode));
+
 #define Channel_IsLocal(c) (Channel_Name(c)[0] == '&')
 #define Channel_IsModeless(c) (Channel_Name(c)[0] == '+')