]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
print out zone if set
authorMark Andrews <marka@isc.org>
Thu, 2 Oct 2003 02:59:58 +0000 (02:59 +0000)
committerMark Andrews <marka@isc.org>
Thu, 2 Oct 2003 02:59:58 +0000 (02:59 +0000)
bin/tests/inter_test.c

index 78edaab48ed1d8836239c6482d598d162a2d7cfe..a2a50d126c5ae28c276cb45e469c4cf3b7651cde 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: inter_test.c,v 1.8 2001/01/09 21:41:09 bwelling Exp $ */
+/* $Id: inter_test.c,v 1.9 2003/10/02 02:59:58 marka Exp $ */
 
 #include <config.h>
 
@@ -54,7 +54,13 @@ main(int argc, char **argv) {
                INSIST(ifdata.af == AF_INET || ifdata.af == AF_INET6);
                res = inet_ntop(ifdata.af, &ifdata.address.type, buf,
                                sizeof(buf));
-               fprintf(stdout, "address = %s\n", res == NULL ? "BAD" : res);
+               if (ifdata.address.zone != 0)
+                       fprintf(stdout, "address = %s (zone %u)\n",
+                               res == NULL ? "BAD" : res,
+                               ifdata.address.zone);
+               else
+                       fprintf(stdout, "address = %s\n",
+                               res == NULL ? "BAD" : res);
                INSIST(ifdata.address.family == ifdata.af);
                res = inet_ntop(ifdata.af, &ifdata.netmask.type, buf,
                                sizeof(buf));