diff options
author | obrien <obrien@FreeBSD.org> | 2000-11-04 20:14:55 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2000-11-04 20:14:55 +0000 |
commit | 7acb11388cf5d680b16902b8ed6f46c46dc4d47b (patch) | |
tree | d18b862b9b680f6a3517a4d5b93c414841a12a47 /contrib/isc-dhcp/common/options.c | |
parent | 68ee0aeb719e4bf0f0beebcd896e4a751f32dfc3 (diff) | |
download | FreeBSD-src-7acb11388cf5d680b16902b8ed6f46c46dc4d47b.zip FreeBSD-src-7acb11388cf5d680b16902b8ed6f46c46dc4d47b.tar.gz |
Import Patchlevel 5 of the ISC 2.0 dhcp client plus bug fixes from the
beta ISC DHCP version 3 offering.
In message http://www.isc.org/ml-archives/dhcp-client/2000/10/msg00001.html
author Ted Lemon stated "This will not be fixed in any 2.0 release - 2.0
is no longer being maintained." to a reported problem about an
interoperability problem against Microsoft servers. FreeBSD went with the
ISC client vs. the WIDE client because others convinced me it was better
supported. Sigh. I wonder if version 3 will get the same treatment after
its release...
Since FreeBSD generally uses only released contrib products and the ISC
version 3 offering is still in beta, our backs are up against the wall.
The common/options.c rev 1.65 work around for erroneous Microsoft DHCP
servers has been back ported to the version 2.0pl5 client. Since this
comes from a change in the vendor's own code (and would no doubt also be
committed to the version 2 client if the author were still supporting it),
we will consider this a vendor release and import this as such.
PR: 21658
Submitted by: Motomichi Matsuzaki <mzaki@e-mail.ne.jp>
Diffstat (limited to 'contrib/isc-dhcp/common/options.c')
-rw-r--r-- | contrib/isc-dhcp/common/options.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/contrib/isc-dhcp/common/options.c b/contrib/isc-dhcp/common/options.c index b80ffa1..b840716 100644 --- a/contrib/isc-dhcp/common/options.c +++ b/contrib/isc-dhcp/common/options.c @@ -553,9 +553,13 @@ char *pretty_print_option (code, data, len, emit_commas, emit_quotes) for (; dp < data + len; dp++) { if (!isascii (*dp) || !isprint (*dp)) { - sprintf (op, "\\%03o", - *dp); - op += 4; + /* Skip trailing NUL. */ + if (dp + 1 != data + len || + *dp != 0) { + sprintf (op, "\\%03o", + *dp); + op += 4; + } } else if (*dp == '"' || *dp == '\'' || *dp == '$' || |