Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 28 May 2019 13:14:53 +0000 (UTC)
From:      Ed Maste <emaste@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r348325 - stable/12/libexec/bootpd
Message-ID:  <201905281314.x4SDErYr040754@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: emaste
Date: Tue May 28 13:14:53 2019
New Revision: 348325
URL: https://svnweb.freebsd.org/changeset/base/348325

Log:
  MFC r348069: bootpd: avoid the same error indication for different issues
  
  There were several (apparently) copy-pasted NEED validation macros,
  leading to the same error string for different issues.  Change the
  YP and NTP tags so they are distinct.
  
  PR:		30863
  Submitted by:	Dan Lukes <dan@obluda.cz>
  Reviewed by:	markj

Modified:
  stable/12/libexec/bootpd/dovend.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/libexec/bootpd/dovend.c
==============================================================================
--- stable/12/libexec/bootpd/dovend.c	Tue May 28 11:45:00 2019	(r348324)
+++ stable/12/libexec/bootpd/dovend.c	Tue May 28 13:14:53 2019	(r348325)
@@ -147,7 +147,7 @@ dovend_rfc1497(hp, buf, len)
 		if (insert_ip(TAG_NIS_SERVER,
 					  hp->nis_server,
 					  &vp, &bytesleft))
-			NEED(8, "ds");
+			NEED(8, "ys");
 	}
 	if (hp->flags.nis_domain) {
 		/*
@@ -155,7 +155,7 @@ dovend_rfc1497(hp, buf, len)
 		 * TAG_NIS_DOMAIN and length.
 		 */
 		len = strlen(hp->nis_domain->string);
-		NEED((len + 2), "dn");
+		NEED((len + 2), "yn");
 		*vp++ = TAG_NIS_DOMAIN;
 		*vp++ = (byte) (len & 0xFF);
 		bcopy(hp->nis_domain->string, vp, len);
@@ -187,7 +187,7 @@ dovend_rfc1497(hp, buf, len)
 		if (insert_ip(TAG_NTP_SERVER,
 					  hp->ntp_server,
 					  &vp, &bytesleft))
-			NEED(8, "ts");
+			NEED(8, "nt");
 	}
 	/*
 	 * I wonder:  If the hostname were "promoted" into the BOOTP



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201905281314.x4SDErYr040754>