summaryrefslogtreecommitdiff
path: root/lib/libc/sys/mqueue/mq_notify.c
blob: 0652da1205ef368b7e7bda6a89493956a6b1cff1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "stddef.h"
#include <errno.h>
#include <mqueue.h>
#include <signal.h>
#include <syscall.h>

int mq_notify(mqd_t mqdes, const struct sigevent *notification)
{
	if (notification == NULL || notification->sigev_notify != SIGEV_THREAD) {
		return syscall(mq_notify, mqdes, notification);
	}

	// TODO: implement SIGEV_THREAD notification
	errno = ENOSYS;
	return -1;
}