changeset 24:5742985b6aa0 draft

Fix yp.conf creation
author Roy Marples <roy@marples.name>
date Wed, 06 Dec 2006 11:34:46 +0000
parents 0c269547f526
children 2fb1ab954ee6
files ChangeLog Makefile configure.c
diffstat 3 files changed, 6 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Wed Dec 06 11:16:43 2006 +0000
+++ b/ChangeLog	Wed Dec 06 11:34:46 2006 +0000
@@ -1,3 +1,6 @@
+dhcpcd-3.0.5
+Fix yp.conf creation.
+
 dhcpcd-3.0.4
 Fix netmask thanks to Marc Duponcheel.
 Send the hostname by default unless null, (none) or localhost.
--- a/Makefile	Wed Dec 06 11:16:43 2006 +0000
+++ b/Makefile	Wed Dec 06 11:34:46 2006 +0000
@@ -1,6 +1,6 @@
 # Should work for both GNU make and BSD mke
 
-VERSION = 3.0.4
+VERSION = 3.0.5
 
 INSTALL ?= install
 CFLAGS ?= -Wall -O2 -pedantic -std=gnu99
--- a/configure.c	Wed Dec 06 11:16:43 2006 +0000
+++ b/configure.c	Wed Dec 06 11:34:46 2006 +0000
@@ -230,10 +230,10 @@
 	fprintf (f, "domain %s broadcast\n", dhcp->nisdomain);
     }
   else
-    sprintf(prefix, "ypserver %c", '\0');
+    snprintf (prefix, sizeof (prefix), "%s", "ypserver");
 
   for (address = dhcp->nisservers; address; address = address->next)
-    fprintf (f, "%s%s\n", prefix, inet_ntoa (address->address));
+    fprintf (f, "%s %s\n", prefix, inet_ntoa (address->address));
 
   fclose (f);