Do not recurse on the glock in rxk_NewSocketHost
authorBen Kaduk <kaduk@mit.edu>
Sun, 4 Jul 2010 02:58:39 +0000 (22:58 -0400)
committerJeffrey Altman <jaltman@openafs.org>
Sun, 4 Jul 2010 05:11:38 +0000 (22:11 -0700)
If sobind() failed, we would lock the glock before going to bad,
which proceeded to lock the glock, panic()ing on the recursion attempt.
Remove the unneeded first call.

Change-Id: Ifa793735ebe64bde98156caa610c06612bdb92bd
Reviewed-on: http://gerrit.openafs.org/2330
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>

src/rx/rx_kcommon.c

index d88ee40..17da066 100644 (file)
@@ -951,7 +951,6 @@ rxk_NewSocketHost(afs_uint32 ahost, short aport)
     if (code) {
        dpf(("sobind fails (%d)\n", (int)code));
        soclose(newSocket);
-       AFS_GLOCK();
        goto bad;
     }
 #else /* defined(AFS_DARWIN_ENV) || defined(AFS_FBSD_ENV) */