Back to index

glibc  2.9
Functions
msgsnd.c File Reference
#include <errno.h>
#include <sys/msg.h>
#include <ipc_priv.h>
#include <sysdep-cancel.h>
#include <sys/syscall.h>
#include <bp-checks.h>

Go to the source code of this file.

Functions

int __libc_msgsnd (int msqid, const void *msgp, size_t msgsz, int msgflg)

Function Documentation

int __libc_msgsnd ( int  msqid,
const void *  msgp,
size_t  msgsz,
int  msgflg 
)

Definition at line 30 of file msgsnd.c.

{
  if (SINGLE_THREAD_P)
    return INLINE_SYSCALL (ipc, 5, IPCOP_msgsnd, msqid, msgsz,
                        msgflg, (void *) CHECK_N (msgp, msgsz));

  int oldtype = LIBC_CANCEL_ASYNC ();

  int result = INLINE_SYSCALL (ipc, 5, IPCOP_msgsnd, msqid, msgsz,
                            msgflg, (void *) CHECK_N (msgp, msgsz));

  LIBC_CANCEL_RESET (oldtype);

  return result;
}