Code

ntpd plugin: Use the `NI_MAXHOST' define for the fixed-size buffer `peername'.
authorLubos Stanek <lubek@users.sourceforge.net>
Sat, 4 Nov 2006 12:17:07 +0000 (13:17 +0100)
committerFlorian Forster <octo@leeloo.lan.home.verplant.org>
Sat, 4 Nov 2006 12:17:07 +0000 (13:17 +0100)
src/ntpd.c

index 520427095c27c300636167d13493d3845114afef..b65a9e8fa72f2dac8e3ed9d1a808f6d9ce4583da 100644 (file)
@@ -882,7 +882,7 @@ static void ntpd_read (void)
                struct info_peer_summary *ptr;
                double offset;
 
-               char peername[512];
+               char peername[NI_MAXHOST];
                int refclock_id;
                
                ptr = ps + i;