From 97d8703809a9e6798b80696da6439ab0887046fb Mon Sep 17 00:00:00 2001 From: Chaskiel M Grundman Date: Tue, 20 Mar 2007 18:41:02 +0000 Subject: [PATCH] keyring-pag-finduser-requires-glock-20070320 identical to the fix from chas@cmf.nrl.navy.mil --- src/afs/LINUX/osi_groups.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/afs/LINUX/osi_groups.c b/src/afs/LINUX/osi_groups.c index fa1cbe12c7..997ec7a684 100644 --- a/src/afs/LINUX/osi_groups.c +++ b/src/afs/LINUX/osi_groups.c @@ -594,13 +594,18 @@ static void afs_pag_destroy(struct key *key) { afs_uint32 pag = key->payload.value; struct unixuser *pu; + int locked = ISAFS_GLOCK(); + if (!locked) + AFS_GLOCK(); pu = afs_FindUser(pag, -1, READ_LOCK); if (pu) { pu->ct.EndTimestamp = 0; pu->tokenTime = 0; afs_PutUser(pu, READ_LOCK); } + if (!locked) + AFS_GUNLOCK(); } struct key_type key_type_afs_pag =