summary refs log tree commit diff
path: root/nis/nis_lookup.c
diff options
context:
space:
mode:
Diffstat (limited to 'nis/nis_lookup.c')
-rw-r--r--nis/nis_lookup.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/nis/nis_lookup.c b/nis/nis_lookup.c
index e194b977e4..4eed61ecdc 100644
--- a/nis/nis_lookup.c
+++ b/nis/nis_lookup.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 1998 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1998, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Thorsten Kukuk <kukuk@uni-paderborn.de>, 1997.
 
@@ -103,6 +103,8 @@ nis_lookup (const_nis_name name, const unsigned int flags)
 	    status = NIS_RPCERROR;
 	  else
 	    {
+	      status = NIS_SUCCESS;
+
 	      if (NIS_RES_STATUS (res) == NIS_SUCCESS)
 		{
 		    if (__type_of(NIS_RES_OBJECT (res)) == NIS_LINK_OBJ &&
@@ -171,7 +173,6 @@ nis_lookup (const_nis_name name, const unsigned int flags)
 	      break;
 	    }
 	  link_first_try = 0; /* Set it back */
-	  status= NIS_SUCCESS;
 	}
       while ((flags & HARD_LOOKUP) && status == NIS_RPCERROR);