]> arthur.barton.de Git - ngircd.git/commitdiff
Fixed server NOTICEs to users with "s" mode ("server messages"). [from HEAD]
authorAlexander Barton <alex@barton.de>
Mon, 29 Aug 2005 11:19:48 +0000 (11:19 +0000)
committerAlexander Barton <alex@barton.de>
Mon, 29 Aug 2005 11:19:48 +0000 (11:19 +0000)
ChangeLog
src/ngircd/log.c

index 3f1fa08da900175293166f66db963792541fade2..0e4caab21d36ab3cfc81114e7319b99be3645011 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -12,6 +12,7 @@
 
 ngIRCd 0.9.x
 
+  - Fixed server NOTICEs to users with "s" mode ("server messages").
   - Fixed a format string bug in "connection statistics" messages to clients.
 
 ngIRCd 0.9.1 (2005-08-03)
@@ -624,4 +625,4 @@ ngIRCd 0.0.1, 31.12.2001
 
 
 -- 
-$Id: ChangeLog,v 1.276.2.8 2005/08/25 09:04:23 alex Exp $
+$Id: ChangeLog,v 1.276.2.9 2005/08/29 11:19:48 alex Exp $
index 459ba1d296da77d5addfe58e93d7e0153e52a518..ff71acb4c96520183ccbbd0aa5f1b27a0b8a6159 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001,2002 by Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2005 Alexander Barton (alex@barton.de)
  *
  * 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
@@ -14,7 +14,7 @@
 
 #include "portab.h"
 
-static char UNUSED id[] = "$Id: log.c,v 1.57 2005/06/24 19:55:10 alex Exp $";
+static char UNUSED id[] = "$Id: log.c,v 1.57.2.1 2005/08/29 11:19:48 alex Exp $";
 
 #include "imp.h"
 #include <assert.h>
@@ -302,19 +302,23 @@ va_dcl
 } /* Log_Resolver */
 
 
+/**
+ * Send log messages to users flagged with the "s" mode.
+ * @param Msg The message to send.
+ */
 LOCAL void
 Wall_ServerNotice( char *Msg )
 {
-       /* Server-Notice an entsprechende User verschicken */
-
        CLIENT *c;
 
        assert( Msg != NULL );
 
        c = Client_First( );
-       while( c )
-       {
-               if(( Client_Conn( c ) > NONE ) && ( Client_HasMode( c, 's' ))) IRC_WriteStrClient( c, "NOTICE %s :%s%s", Client_ThisServer( ), NOTICE_TXTPREFIX, Msg );
+       while(c) {
+               if (Client_Conn(c) > NONE && Client_HasMode(c, 's'))
+                       IRC_WriteStrClient(c, "NOTICE %s :%s%s", Client_ID(c),
+                                                       NOTICE_TXTPREFIX, Msg);
+
                c = Client_Next( c );
        }
 } /* Wall_ServerNotice */