Fix fencepost error; use argv[1] to test for a specfied host if argc
authorTheodore Tso <tytso@mit.edu>
Wed, 13 Sep 1995 17:59:23 +0000 (17:59 +0000)
committerTheodore Tso <tytso@mit.edu>
Wed, 13 Sep 1995 17:59:23 +0000 (17:59 +0000)
is >= 1, not just > 1.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6775 dc483132-0cff-0310-8789-dd5450dbe970

src/tests/resolve/ChangeLog
src/tests/resolve/resolve.c

index aa74e10dbcda5a22152a4e046d02a5b0a6e274a0..9b9269b9e03ab9cee20c0e1432a6961091c3952c 100644 (file)
@@ -1,3 +1,7 @@
+Wed Sep 13 13:57:40 1995  Theodore Y. Ts'o  <tytso@dcl>
+
+       * resolve.c (main): Fix fencepost error; use argv[1] to test for a
+               specfied host if argc is >= 1, not just > 1.
 
 Wed Jul 12 12:32:14 EDT 1995   Paul Park       (pjpark@mit.edu)
        * Makefile.in - Add LD_LIBRARY_PATH in case we were linked with shared
index af292e051fdbdbe8f375ec430a3b60e873f2e857..90cf1d256b688612e62488a86ae330299a739c7c 100644 (file)
@@ -81,7 +81,7 @@ main(argc, argv)
            argc--; argv++;
        }
 
-       if (argc > 1) {
+       if (argc >= 1) {
                strncpy(myname, *argv, MAXHOSTNAMELEN);
        } else {
                if(gethostname(myname, MAXHOSTNAMELEN)) {