From 12570db7c9e40aaf5905167bb3ef5c7b5e5e7161 Mon Sep 17 00:00:00 2001 From: Derrick Brashear Date: Fri, 15 Oct 2010 16:27:55 -0400 Subject: [PATCH] vutil use lockfile mutex macros for lockfile mutex we have macroes; let's use them. makes later changes easier. Change-Id: If128930f659c34592c27503a02d64b67d7f60a84 Reviewed-on: http://gerrit.openafs.org/2996 Reviewed-by: Jeffrey Altman Reviewed-by: Rod Widdowson Reviewed-by: Andrew Deason Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- src/vol/vutil.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/vol/vutil.c b/src/vol/vutil.c index f47b8997ab..8c6719a67e 100644 --- a/src/vol/vutil.c +++ b/src/vol/vutil.c @@ -1087,9 +1087,7 @@ _VUnlockFd(int fd, afs_uint32 offset) void VLockFileReinit(struct VLockFile *lf) { -#ifdef AFS_PTHREAD_ENV - assert(pthread_mutex_lock(&lf->mutex) == 0); -#endif /* AFS_PTHREAD_ENV */ + AFS_LF_LOCK(lf); if (lf->fd != INVALID_FD) { _VCloseFd(lf->fd); @@ -1098,9 +1096,7 @@ VLockFileReinit(struct VLockFile *lf) lf->refcount = 0; -#ifdef AFS_PTHREAD_ENV - assert(pthread_mutex_unlock(&lf->mutex) == 0); -#endif /* AFS_PTHREAD_ENV */ + AFS_LF_UNLOCK(lf); } /**