svn commit: r284229 - head/lib/libc/resolv
Hajimu UMEMOTO
ume at FreeBSD.org
Wed Jun 10 16:15:23 UTC 2015
Author: ume
Date: Wed Jun 10 16:15:22 2015
New Revision: 284229
URL: https://svnweb.freebsd.org/changeset/base/284229
Log:
Add support for '_' occurring at the beginning or end of a name
component.
PR: 176093
Submitted by: landonf__at__bikemonkey.org
MFC after: 1 week
Modified:
head/lib/libc/resolv/res_comp.c
Modified: head/lib/libc/resolv/res_comp.c
==============================================================================
--- head/lib/libc/resolv/res_comp.c Wed Jun 10 16:00:09 2015 (r284228)
+++ head/lib/libc/resolv/res_comp.c Wed Jun 10 16:15:22 2015 (r284229)
@@ -147,12 +147,12 @@ dn_skipname(const u_char *ptr, const u_c
|| ((c) >= 0x61 && (c) <= 0x7a))
#define digitchar(c) ((c) >= 0x30 && (c) <= 0x39)
-#define borderchar(c) (alphachar(c) || digitchar(c))
#ifdef RES_ENFORCE_RFC1034
-#define middlechar(c) (borderchar(c) || hyphenchar(c))
+#define borderchar(c) (alphachar(c) || digitchar(c))
#else
-#define middlechar(c) (borderchar(c) || hyphenchar(c) || underscorechar(c))
+#define borderchar(c) (alphachar(c) || digitchar(c) || underscorechar(c))
#endif
+#define middlechar(c) (borderchar(c) || hyphenchar(c))
#define domainchar(c) ((c) > 0x20 && (c) < 0x7f)
int
More information about the svn-src-all
mailing list