#include <afs/param.h>
#include <roken.h>
+#include <afs/opr.h>
#include <rx/xdr.h>
#include <rx/rx.h>
#include "acl.h"
#ifdef AFS_PTHREAD_ENV
-#include <assert.h>
#include <pthread.h>
pthread_mutex_t acl_list_mutex;
#endif /* AFS_PTHREAD_ENV */
ACL_VERSION, version);
}
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_init(&acl_list_mutex, NULL) == 0);
+ opr_Verify(pthread_mutex_init(&acl_list_mutex, NULL) == 0);
#endif /* AFS_PTHREAD_ENV */
return 0;
}
{
/* Adds elem to the freelist flist; returns 0 */
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_lock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_lock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
elem->next = *pflist;
*pflist = elem;
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_unlock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_unlock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
return 0;
}
struct freeListEntry *y, *z;
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_lock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_lock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
if (*pflist == NULL) {
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_unlock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_unlock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
return -1;
}
if (z == NULL) { /* pulling off the head */
*pflist = y->next;
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_unlock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_unlock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
return 0;
}
z->next = y->next;
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_unlock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_unlock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
return 0;
}
}
#ifdef AFS_PTHREAD_ENV
- assert(pthread_mutex_unlock(&acl_list_mutex) == 0);
+ opr_Verify(pthread_mutex_unlock(&acl_list_mutex) == 0);
#endif /* AFS_PTHREAD_ENV */
return -1;
}