diff options
author | Ted Lemon <source@isc.org> | 2001-01-16 23:12:47 +0000 |
---|---|---|
committer | Ted Lemon <source@isc.org> | 2001-01-16 23:12:47 +0000 |
commit | 4cb55919c26e1e0c6ff9d66a7f732d6e617f49a9 (patch) | |
tree | 599007379655e7f8ef47323be289de3751807dbb /common/print.c | |
parent | 1898dcf70dcbce0361b1a84e315c4d793fd21314 (diff) | |
download | isc-dhcp-4cb55919c26e1e0c6ff9d66a7f732d6e617f49a9.tar.gz |
- Print null hardware address as blank, instead of as <null>.
- Use isc_result_totext to print ns update status, now that res_nupdate
is returning an isc_result_t.
Diffstat (limited to 'common/print.c')
-rw-r--r-- | common/print.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/common/print.c b/common/print.c index 93e35825..7fd0ebeb 100644 --- a/common/print.c +++ b/common/print.c @@ -43,7 +43,7 @@ #ifndef lint static char copyright[] = -"$Id: print.c,v 1.47 2001/01/06 21:32:26 mellon Exp $ Copyright (c) 1995, 1996, 1998, 1999 The Internet Software Consortium. All rights reserved.\n"; +"$Id: print.c,v 1.48 2001/01/16 23:12:47 mellon Exp $ Copyright (c) 1995, 1996, 1998, 1999 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ #include "dhcpd.h" @@ -57,9 +57,9 @@ char *print_hw_addr (htype, hlen, data) char *s; int i; - if (htype == 0 || hlen == 0) { - strcpy (habuf, "<null>"); - } else { + if (hlen == 0) + habuf [0] = 0; + else { s = habuf; for (i = 0; i < hlen; i++) { sprintf (s, "%02x", data [i]); @@ -1169,6 +1169,8 @@ void print_dns_status (int status, ns_updque *uq) s += strlen (s); } errorp = 1; + en = isc_result_totext (status); +#if 0 switch (status) { case -1: en = "resolver failed"; @@ -1223,6 +1225,7 @@ void print_dns_status (int status, ns_updque *uq) en = "unknown error"; break; } +#endif if (s + 2 < end) { *s++ = ':'; |