Commit Graph

126 Commits

Author SHA1 Message Date
Alexander Barton f92a614a35 Enable KICK to be handled from remote servers and from services. 2008-09-23 11:53:16 +02:00
Alexander Barton 3913de3cff Fix PRIVMSG/NOTICE handler (II): keep command when forwarding to channels.
- new function ngt_UpperStr().
- change Channel_Write() to take command name and error flag.
- remove now unneeded function Channel_Notice().
2008-09-23 11:53:15 +02:00
Alexander Barton b92a7627f3 Don't allow empty channel names ("#") in strict RFC mode.
This closes Bug #88.

Patch proposed by Eric <egrunow@ucsd.edu>, but with wrong length
comparision: please note that Channel_IsValidName() checks the name
INCLUDING the prefix, so the test must be length<=1!
2008-07-22 13:24:14 +02:00
Alexander Barton 477f2fd9e7 Channel_Join(): Code cleanup. 2008-07-22 13:07:57 +02:00
Eric Grunow 71562ebe57 Translated comments from German to English 2008-06-16 13:58:56 +02:00
Eric Grunow 75b719a0c8 Anglified and improved comments in channel.c and channel.h
[Dana Dahlstrom: repair tab/space conversion in patch]
2008-05-08 03:15:04 +02:00
Florian Westphal 0428a1c4ea Constify some of Channel_Kick()s arguments. 2008-05-05 15:38:47 +02:00
Florian Westphal f7c2e8223f Always enable modeless channels.
Modeless channels (+channels) are described in RFC 2811;
so my modifications to
530112b114
('Add support for modeless channels')
to disable +channels for --strict-rfc configurations
were wrong. This reverts those changes.
2008-05-01 18:08:07 +02:00
Ali Shemiran 530112b114 Add support for modeless channels
Add support for modeless channels (+channels).

[fw@strlen.de:
 - integrate test cases
 - don't support +channels when compiled with --strict-rfc
 - do not set +o mode for channel creator
 - force +nt mode when channel is created ]
2008-05-01 15:55:12 +02:00
Alexander Barton 523a6fad09 Report ERR_NOTONCHANNEL when trying to part a channel one is not member of.
When trying to part a channel ("PART #channel") the client is not member of
the daemon now correctly reports the numeric ERR_NOTONCHANNEL (442) insted
of ERR_NOSUCHCHANNEL (403).
2008-04-24 23:52:54 +02:00
Alexander Barton 54b17fc201 Channel_Part(): Code and comment cleanup. 2008-04-24 23:47:33 +02:00
Florian Westphal cb0d594e61 Make Channel_Part name and reason parameters 'const'. 2008-02-26 23:49:33 +01:00
Florian Westphal 59b19ea6a3 This adds support for sending NOTICEs to a channel.
[also see Bug #70 in ngircd bugzilla].

Based on a patch by Fabian Schlager <fabian.schlager@gmail.com>.
2008-02-26 23:49:33 +01:00
Florian Westphal 5675be4cd9 fix compile /w gcc 2.95 (reported by Tassilo Schweyer) 2007-06-11 20:06:46 +00:00
Florian Westphal 1b852fce72 add support for predefined-channel configuration of k and l modes 2006-12-29 14:09:48 +00:00
Florian Westphal fb0fbe908d remove unused function Channel_PCount 2006-12-07 22:23:39 +00:00
Florian Westphal fa7bb2790a moved invite/ban lists to channel structure 2006-12-07 17:57:20 +00:00
Florian Westphal 6e105bf87e channel maxusers now unsigned long 2006-10-06 21:32:58 +00:00
Florian Westphal d8950c5dd0 cleaned up Channel_IsValidName (now uses strcspn()) 2006-10-02 21:55:49 +00:00
Florian Westphal e2aacff7d4 s/Log(LOG_DEBUG/LogDebug(/ , translated comments, etc. 2006-08-12 11:58:21 +00:00
Alexander Barton 47026e14ce Don't assert() when a pre-defined channel has no topic. 2006-07-24 22:54:09 +00:00
Florian Westphal 8067bab106 changes some comments, minor cleanup 2006-04-23 10:33:37 +00:00
Alexander Barton ca32c1b311 Implementec numeric "333": Time and user name who set a channel topic. 2005-09-02 12:50:25 +00:00
Alexander Barton 77f54693ef Removed unnecessary #define of "LOCAL", now use plain C "static" instead. 2005-07-31 20:13:07 +00:00
Florian Westphal 84706af7fe topic no longer limited to 127 chars (now only limited by protocol) 2005-07-28 16:23:55 +00:00
Florian Westphal 70facb7f6e made a few config options unsigned. 2005-07-11 14:11:35 +00:00
Florian Westphal d81dab99fa put badchars back in 2005-06-18 08:57:37 +00:00
Florian Westphal aec535c8b6 s/sprintf/snprintf 2005-06-17 19:16:53 +00:00
Florian Westphal 517321807e Fix Handling of quit messages: always send only one QUIT message. 2005-06-04 11:53:24 +00:00
Alexander Barton dfe662ad45 Added missing #include of "defines.h". 2005-04-27 07:34:25 +00:00
Florian Westphal 8adff59223 Remove INT, LONG, BOOLEAN, STATIC, CONST, CHAR datatypes.
use stdbool.h / inttypes.h if available.
2005-03-19 18:43:48 +00:00
Alexander Barton cb76d96efb Fixed some warnings of non-gcc-compilers (e. g. original Apple compiler on
A/UX): "warning: illegal pointer combination, op =".
2004-03-11 22:16:31 +00:00
Alexander Barton 57c7e23622 Added #include for strings.h to fix compiler warnings. 2004-01-17 03:17:49 +00:00
Alexander Barton be79fabcbf Fixed ban behavior: users which are banned from a channel can't no longer
send PRIVMSG's to this channel (fixes Bug #47).
2003-11-06 01:07:44 +00:00
Alexander Barton b8d7dcec77 - Adjusted includes for new "conn-func.h" header. 2002-12-30 17:15:42 +00:00
Alexander Barton 6626395c88 - replaced a lot of strcat() calls with strlcat() which is more secure. 2002-12-26 16:48:14 +00:00
Alexander Barton 0ced4181b0 - replaced all strncpy()'s and strncat()'s with strlcpy() and strlcat(). 2002-12-26 16:25:43 +00:00
Alexander Barton d9a13b317e - fixed some warnings that showed up with -Wtraditional 2002-12-25 13:22:43 +00:00
Alexander Barton 2e88dd72d1 - New functions Channel_[Set]Key(), Channel_[Set]MaxUsers. 2002-12-16 23:05:24 +00:00
Alexander Barton e907816380 - fixed up Channel_PCount() and Channel_CountForUser(). 2002-12-14 13:21:56 +00:00
Alexander Barton b7eb5f66dc - new function Channel_CountForUser(). 2002-12-13 17:22:57 +00:00
Alexander Barton 490f28ffd1 - new file header format (in english);
- new file ident semantics.
2002-12-12 12:24:18 +00:00
Alexander Barton 7233b72145 - Channel_InitPredefined() prueft nun, ob ein Channel bereits existiert. 2002-11-22 17:57:15 +00:00
Alexander Barton c7b55aa6f4 - verwendete Datentypen aufgeraumt: beispielsweise INT32 ist nun oft ein LONG. 2002-10-09 16:53:02 +00:00
Alexander Barton 378e511e04 - New_Chan() in Channel_Create() umbenannt; entsprechende Anpassungen.
- Neue Funktion Channel_SetModes().
2002-09-03 23:57:57 +00:00
Alexander Barton adcd9289c2 - vorkonfigurierte Channel: Fehlerhaften Test "kein Null-Name" korrigiert. 2002-09-02 18:23:35 +00:00
Alexander Barton 7d30c8cebc - Hmpf. "Verfruehtes" CVS-Update einiger Source-Files zurueckgenommen ... 2002-08-26 23:47:58 +00:00
Alexander Barton d645ce86e9 - Bei einem JOIN in einen persistenten Channel werden nun evtl. zu setzende
User-Modes korrekt in den Channel gemeldet.
2002-08-26 23:39:22 +00:00
Alexander Barton 1fd7215def - Besseres Logging, wenn malloc() fehl schlaegt.
- Ban- und Invite-Lists werden korrekt aufgeraeumt.
2002-06-09 13:15:58 +00:00
Alexander Barton 04162c3944 - Neue Funktion Channel_InitPredefined(). 2002-06-02 17:13:07 +00:00
Alexander Barton 22365b2c55 - QUIT wurde mir falschem Prefix verschickt. 2002-06-01 15:55:17 +00:00
Alexander Barton cc1e8514f8 - neue Funktionen Channel_Kick() und Channel_Quit();
- Channel_RemoveClient() ist entfallen.
- Remove_Client() ueberarbeitet: nun mit Unterstuetzung fuer PART, QUIT und KICK.
2002-06-01 14:35:39 +00:00
Alexander Barton f7327524fc - Weitere Anpassungen an pre-ANSI-Compiler. 2002-05-30 16:52:20 +00:00
Alexander Barton c2f60abe55 - Anpassungen an pre-ANSI-Compiler,
- Includes aufgeraumt: Header includieren keine anderen mehr.
2002-05-27 13:09:26 +00:00
Alexander Barton 040f5422f2 - persistente und vordefinierte Channels implementiert. 2002-05-21 00:10:16 +00:00
Alexander Barton f22f1cf4f4 - neue Funktion Channel_MemberCount() implementiert. 2002-04-23 19:51:31 +00:00
Alexander Barton 0e38d10bcd - New_Chan() berechnet Hash-Werte ueber den Namen.
- Channel_Search() verwendet nun Hash-Werte.
- Neue Funktion Channel_Write().
2002-03-25 16:54:26 +00:00
Alexander Barton ca33cbda05 - externe portab-Header werden nicht mehr benoetigt/benutzt, dadurch
einige Aenderungen an diversen Source-Dateien und Headern.
- Dateien enthalten keine CVS-History mehr.
2002-03-12 14:37:51 +00:00
Alexander Barton 10363b398e - strncpy() und vsnprintf() kopieren nun etwas "optimierter" (1 Byte weniger) :-) 2002-03-03 17:17:01 +00:00
Alexander Barton 7157d93651 - Channel- und Nicknames werden nun ordentlich validiert. 2002-03-02 01:35:50 +00:00
Alexander Barton ff54198f43 - Includes fuer einige Header bereinigt. 2002-02-27 23:23:53 +00:00
Alexander Barton 52548bd3e3 - neue Funktionen Channel_Topic() und Channel_SetTopic(). 2002-02-27 20:32:10 +00:00
Alexander Barton 153aa0aac8 - neue Funktion Channel_IsMemberOf() implementiert. 2002-02-27 15:21:21 +00:00
Alexander Barton d72c55a09d - neue Funktionen Channel_ModeAdd(), Channel_ModeDel(), Channel_UserModes(),
Channel_UserModeAdd(), Channel_UserModeDel().
- Modes in CL2CHAN-Struktur werden nun korrekt initialisiert.
2002-02-11 01:00:12 +00:00
Alexander Barton f53914b17a - neue Funktion Channel_Modes() und Channel_IsValidName().
- Channel-Namen werden (besser) validiert.
2002-02-06 16:48:48 +00:00
Alexander Barton 0bb9db1aa0 - neue Funktionen Channel_FirstChannelOf() und Channel_NextChannelOf(). 2002-01-29 00:11:10 +00:00
Alexander Barton 71c7a6fcc0 - neue Funktionen Channel_Name(), Channel_First() und Channel_Next(). 2002-01-28 01:16:15 +00:00
Alexander Barton 6491b9843f - PART wird nicht mehr an den Server verschickt, von dem es empfangen wurde. 2002-01-27 22:47:11 +00:00
Alexander Barton b5ee4552c1 - weitere Anpassungen an Chennals, v.a. ueber Server-Links. 2002-01-27 21:56:54 +00:00
Alexander Barton d569c9246e - diverse Aenderungen fuer Channels ueber mehrere Server. 2002-01-27 17:14:33 +00:00
Alexander Barton 8a324b6d9c - CHANNEL- und CL2CHAN-Strukturen in Header verlegt,
- einige neue Funktionen (Channel_GetChannel(), Channel_FirstMember(), ...)
2002-01-26 18:41:55 +00:00
Alexander Barton bb19cfda95 - begonnen, Channels zu implementieren :-) 2002-01-21 00:12:29 +00:00
Alexander Barton 568239244f - neue Funktion Channel_Count(). 2002-01-16 22:09:07 +00:00
Alexander Barton 1547f76cfd - Copyright-Texte aktualisiert. 2002-01-02 02:42:58 +00:00
Alexander Barton 804b1ec498 - viele neue Befehle (WHOIS, ISON, OPER, DIE, RESTART),
- neuen Header "defines.h" mit (fast) allen Konstanten.
- Code Cleanups und viele "kleine" Aenderungen & Bugfixes.
2001-12-31 02:18:51 +00:00
Alexander Barton 38b9cb88c1 - neues Modul begonnen :-) 2001-12-14 08:13:43 +00:00