]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
* nis/nis_call.c (__nisbind_create): Remove __nisbind_destroy,
authorUlrich Drepper <drepper@redhat.com>
Thu, 8 Dec 2005 20:32:12 +0000 (20:32 +0000)
committerUlrich Drepper <drepper@redhat.com>
Thu, 8 Dec 2005 20:32:12 +0000 (20:32 +0000)
->clnt cannot be != NULL.
(__do_niscall): No need to use __nisbind_destroy, __nisbind_next
did it.
(__nisbind_connect): use_auth is already TRUE, otherwise we would
not be here.

* nis/nis_lookup.c (nis_lookup): Remove unnecessary
__nisbind_destroy calls.  __nisbind_next does all that.

ChangeLog
nis/nis_call.c
nis/nis_lookup.c

index e7a2187843a6310b98d6d54d527b6783f1b7706b..7bfbb3003cd7dcec407251b882a3c25b6fd6f854 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
 2005-12-08  Jakub Jelinek  <jakub@redhat.com>
 
+       * nis/nis_call.c (__nisbind_create): Remove __nisbind_destroy,
+       ->clnt cannot be != NULL.
+       (__do_niscall): No need to use __nisbind_destroy, __nisbind_next
+       did it.
+       (__nisbind_connect): use_auth is already TRUE, otherwise we would
+       not be here.
+
+       * nis/nis_lookup.c (nis_lookup): Remove unnecessary
+       __nisbind_destroy calls.  __nisbind_next does all that.
+
        * nis/ypclnt.c (yp_update): Before trying default authentication,
        free DES descriptor.
 
index 14041a160c40cd8ce4e87dfa2970274c41af260e..07f95f041c66057a11eb0b9e5f60ded9c73e441d 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 1998, 2001, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1998, 2001, 2004, 2005 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Thorsten Kukuk <kukuk@vt.uni-paderborn.de>, 1997.
 
@@ -179,7 +179,6 @@ __nisbind_connect (dir_binding *dbp)
        }
       else
        dbp->clnt->cl_auth = authunix_create_default ();
-      dbp->use_auth = TRUE;
     }
 
   return NIS_SUCCESS;
@@ -215,10 +214,7 @@ __nisbind_create (dir_binding *dbp, const nis_server *serv_val,
 
   dbp->class = -1;
   if (__nis_findfastest (dbp) < 1)
-    {
-      __nisbind_destroy (dbp);
-      return NIS_NAMEUNREACHABLE;
-    }
+    return NIS_NAMEUNREACHABLE;
 
   return NIS_SUCCESS;
 }
@@ -585,7 +581,6 @@ __do_niscall (const_nis_name name, u_long prog, xdrproc_t xargs,
          if (__nisbind_next (&bptr) != NIS_SUCCESS)
            {
              nis_free_directory (dir);
-             __nisbind_destroy (&bptr);
              return NIS_NAMEUNREACHABLE;
            }
        }
index 5f2fb59d79c0a8978e2298e270350274c4755469..4cb34dd1a852e2d0cdf797ad09a688c12a583ac1 100644 (file)
@@ -81,7 +81,6 @@ nis_lookup (const_nis_name name, const unsigned int flags)
        {
          if (__nisbind_next (&bptr) != NIS_SUCCESS)
            {
-             __nisbind_destroy (&bptr);
              nis_free_directory (dir);
              NIS_RES_STATUS (res) = NIS_NAMEUNREACHABLE;
              return res;
@@ -167,7 +166,6 @@ nis_lookup (const_nis_name name, const unsigned int flags)
                      {
                        if (__nisbind_next (&bptr) != NIS_SUCCESS)
                          {
-                           __nisbind_destroy (&bptr);
                            nis_free_directory (dir);
                            return res;
                          }