]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
move the calculation of remaining
authorMark Andrews <marka@isc.org>
Thu, 16 Sep 2004 02:12:37 +0000 (02:12 +0000)
committerMark Andrews <marka@isc.org>
Thu, 16 Sep 2004 02:12:37 +0000 (02:12 +0000)
bin/dig/dig.c

index 103963c8be2366489b023359a84f7e2365285557..b6afa4fa04717a31954151a3ca47fee6f35e9140 100644 (file)
@@ -15,7 +15,7 @@
  * PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: dig.c,v 1.198 2004/09/16 01:01:25 marka Exp $ */
+/* $Id: dig.c,v 1.199 2004/09/16 02:12:37 marka Exp $ */
 
 #include <config.h>
 #include <stdlib.h>
@@ -636,9 +636,9 @@ printgreeting(int argc, char **argv, dig_lookup_t *lookup) {
                                 "; (%d server%s found)\n",
                                 addresscount,
                                 addresscount > 1 ? "s" : "");
-                       strncat(lookup->cmdline, append, remaining);
                        remaining = sizeof(lookup->cmdline) -
                                    strlen(lookup->cmdline) - 1;
+                       strncat(lookup->cmdline, append, remaining);
                }
                if (first) {
                        snprintf(append, sizeof(append),