Netscape DIRECTORY SERVER 6.02 - PLUG-IN Manual page 482

Table of Contents

Advertisement

Functions for Managing Locks and Synchronization
mutex
Returns
This function returns one of the following values:
A pointer to the new
NULL
Description
This function creates a new condition variable and returns a pointer to the
Slapi_CondVar
slapi_new_mutex()
To wait on the condition variable, call the slapi_wait_condvar() function. To notify
waiting threads, call the
When you are done working with this
slapi_destroy_condvar()
slapi_new_mutex()
Creates a new mutex and returns a pointer to the corresponding
structure.
Syntax
#include "slapi-plugin.h"
Slapi_Mutex *slapi_new_mutex();
Returns
This function returns one of the following values:
A pointer to the new
NULL
Description
This function creates a new mutex and returns a pointer to the
structure. You can lock this mutex by calling the
function and unlock the mutex by calling the
482
Netscape Directory Server Plug-In Programmer's Guide • May 2002
Pointer to an Slapi_Mutex structure representing the mutex
that you want used to protect this condition variable.
Slapi_CondVar
if memory cannot be allocated.
structure. You can create the
function.
slapi_notify_condvar()
function to free the structure from memory.
Slapi_Mutex
if memory cannot be allocated.
structure.
structure by calling the
Slapi_Mutex
function.
structure, call the
Slapi_CondVar
structure.
slapi_pblock_destroy()
slapi_unlock_mutex()
Slapi_Mutex
Slapi_Mutex
function.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Directory server 6.02

Table of Contents