| Previous | Contents | Index |
Initialize PMDF data structures and resources.
status = PMDF_initialize (ischannel)
Argument Data type Access Mechanism ischannel boolean read reference
status = PMDFinitialize (ischannel)
int PMDFinitialize(int ischannel)
ischannel
If true, then user-to-channel access checks will be disabled. If false, then user-to-channel access checks will be enabled.
With the exception ofPMDFsetMutex,PMDFinitializemust be called prior to calling any other API routines. This allocates and initializes internal data structures used by the API and PMDF.PMDFinitializeshould only be called once. After all processing is completed,PMDFdoneshould be called to release any allocated memory, and ensure that any open files are properly closed. The ischannel flag is used to enable or disable rightslist based user-to-channel access checks. Programs which enqueue messages in behalf of users (e.g., user agents), should invokePMDFinitializewith ischannel false; channel programs which enqueue mail should invokePMDFinitializewith ischannel true. When ischannel is false,PMDFenqueueMessagewill also close the queue cache database after enqueuing a message. On OpenVMS systems, channel programs which run indefinitely (e.g., detached processes) should supply a call back procedure toPMDFsetCallBackso that when a PMDF CACHE/CLOSE command is issued the program can callPMDFcloseQueueCachewhen convenient. See Section 1.7 for a further discussion of this issue. Multithreaded routines must callPMDFsetMutexprior to callingPMDFinitialize.
PMDF__OK Normal, successful completion. PMDF__FOPN Initialization failed. One or more PMDF configuration files could not be accessed. PMDF configuration files are incorrectly protected. Note that the use of PMDFinitializedoes not require any privileges; unprivileged users should be able to invoke this particular routine.PMDF__NO Initialization failed owing to a version mismatch between the current version of PMDF and the sites compiled configuration. Either the PMDF configuration needs to be recompiled or the character set tables need to be recompiled.
| Previous | Next | Contents | Index |