about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorAlexander Barton <alex@barton.de>2002-04-14 14:02:35 +0000
committerAlexander Barton <alex@barton.de>2002-04-14 14:02:35 +0000
commit7f795915223bb416fafc6b00f161c410a0a22b76 (patch)
tree4e0ae727eb6861f2552f32e917d044699f8fdd2d /src
parent3be7b9ef59cf7425c87e4b44c7345287eb13c425 (diff)
downloadngircd-7f795915223bb416fafc6b00f161c410a0a22b76.tar.gz
ngircd-7f795915223bb416fafc6b00f161c410a0a22b76.zip
- IRC_QUIT(): der QUIT-Befehl wird nun auch von unreg. Clients akzeptiert.
Diffstat (limited to 'src')
-rw-r--r--src/ngircd/irc-login.c29
1 files changed, 14 insertions, 15 deletions
diff --git a/src/ngircd/irc-login.c b/src/ngircd/irc-login.c
index 93998f59..a23788c2 100644
--- a/src/ngircd/irc-login.c
+++ b/src/ngircd/irc-login.c
@@ -9,7 +9,7 @@
  * Naehere Informationen entnehmen Sie bitter der Datei COPYING. Eine Liste
  * der an ngIRCd beteiligten Autoren finden Sie in der Datei AUTHORS.
  *
- * $Id: irc-login.c,v 1.12 2002/04/08 16:37:50 alex Exp $
+ * $Id: irc-login.c,v 1.13 2002/04/14 14:02:35 alex Exp $
  *
  * irc-login.c: Anmeldung und Abmeldung im IRC
  */
@@ -252,19 +252,7 @@ GLOBAL BOOLEAN IRC_QUIT( CLIENT *Client, REQUEST *Req )
 	assert( Client != NULL );
 	assert( Req != NULL );
 
-	if(( Client_Type( Client ) == CLIENT_USER ) || ( Client_Type( Client ) == CLIENT_SERVICE ))
-	{
-		/* User / Service */
-		
-		/* Falsche Anzahl Parameter? */
-		if( Req->argc > 1 ) return IRC_WriteStrClient( Client, ERR_NEEDMOREPARAMS_MSG, Client_ID( Client ), Req->command );
-
-		if( Req->argc == 0 ) Conn_Close( Client_Conn( Client ), "Got QUIT command.", NULL, TRUE );
-		else Conn_Close( Client_Conn( Client ), "Got QUIT command.", Req->argv[0], TRUE );
-		
-		return DISCONNECTED;
-	}
-	else if ( Client_Type( Client ) == CLIENT_SERVER )
+	if ( Client_Type( Client ) == CLIENT_SERVER )
 	{
 		/* Server */
 
@@ -284,7 +272,18 @@ GLOBAL BOOLEAN IRC_QUIT( CLIENT *Client, REQUEST *Req )
 
 		return CONNECTED;
 	}
-	else return IRC_WriteStrClient( Client, ERR_NOTREGISTERED_MSG, Client_ID( Client ));
+	else
+	{
+		/* User, Service, oder noch nicht registriert */
+		
+		/* Falsche Anzahl Parameter? */
+		if( Req->argc > 1 ) return IRC_WriteStrClient( Client, ERR_NEEDMOREPARAMS_MSG, Client_ID( Client ), Req->command );
+
+		if( Req->argc == 0 ) Conn_Close( Client_Conn( Client ), "Got QUIT command.", NULL, TRUE );
+		else Conn_Close( Client_Conn( Client ), "Got QUIT command.", Req->argv[0], TRUE );
+		
+		return DISCONNECTED;
+	}
 } /* IRC_QUIT */