[NeoStats-Devel] [Commits] r2823 - in trunk: include src
[email protected] Tue, 20 Sep 2005 06:53:43 +1000
| Newsgroups | gmane.comp.neostats.devel |
|---|---|
| Message-ID | <[email protected]> |
Author: Mark
Date: Tue Sep 20 04:53:42 2005
New Revision: 2823
Modified:
trunk/include/neostats.h
trunk/src/servers.c
Log:
make server info field format specifier trusted
Modified: trunk/include/neostats.h
==============================================================================
--- trunk/include/neostats.h (original)
+++ trunk/include/neostats.h Tue Sep 20 04:53:42 2005
@@ -394,7 +394,7 @@
#define MODESIZE 53
#define PARAMSIZE MAXNICK+MAXUSER+MAXHOST+10
-#define MAXINFO 128
+#define MAXINFO MAXREALNAME
#define B64SIZE 16
#define KEYLEN (32 + 1)
Modified: trunk/src/servers.c
==============================================================================
--- trunk/src/servers.c (original)
+++ trunk/src/servers.c Tue Sep 20 04:53:42 2005
@@ -97,7 +97,10 @@
s->uplink = FindServer( uplink );
}
if( infoline )
- strlcpy( s->info, infoline, MAXINFO );
+ {
+ strlcpy( s->info, infoline, MAXREALNAME );
+ clean_string( s->info, MAXREALNAME );
+ }
if( numeric )
s->server->numeric = atoi( numeric );
s->tsconnect = me.now;