Standards / Extensions | C or C++ | Dependencies |
---|---|---|
z/OS® UNIX | both |
#define _XOPEN_SOURCE
#include <sys/__getipc.h>
int __getipc(int token_id, IPCQPROC *bufptr, size_t buflng, int cmd);
The __getipc() function provides means for obtaining information about the status of interprocess communications (IPC) resources, message queues, semaphores, shared memory, and map service memory.
The argument token_id is a number that identifies the relative position of an IPC member in the system or specifies a message queue ID, semaphore ID, or shared memory ID. Zero represents the first IPC member ID in the system. On the first call to __getipc(), pass the a token_id of zero; the function will return the token that identifies the next IPC resource to which the caller has access. Use this token on the next call to __getipc().
The argument bufptr is the address where the data is to be stored.
The argument buflen is the length of the buffer.
If successful, __getipc() returns 0.