1 /* cygserver_msg.h: Single unix specification IPC interface for Cygwin.
3 This file is part of Cygwin.
5 This software is a copyrighted work licensed under the terms of the
6 Cygwin license. Please consult the file "CYGWIN_LICENSE" for
9 #ifndef __CYGSERVER_MSG_H__
10 #define __CYGSERVER_MSG_H__
12 #include <sys/types.h>
13 #include <sys/sysproto.h>
17 #include <cygwin/msg.h>
19 #include "cygserver.h"
20 #include "cygserver_ipc.h"
22 #ifndef __INSIDE_CYGWIN__
23 class transport_layer_base
;
27 class client_request_msg
: public client_request
29 friend class client_request
;
49 struct msgctl_args ctlargs
;
50 struct msgget_args getargs
;
51 struct msgrcv_args rcvargs
;
52 struct msgsnd_args sndargs
;
62 #ifndef __INSIDE_CYGWIN__
63 client_request_msg ();
64 virtual void serve (transport_layer_base
*, process_cache
*);
69 #ifdef __INSIDE_CYGWIN__
70 client_request_msg (int, int, struct msqid_ds
*); // msgctl
71 client_request_msg (key_t
, int); // msgget
72 client_request_msg (int, void *, size_t, long, int); // msgrcv
73 client_request_msg (int, const void *, size_t, int); // msgsnd
76 int retval () const { return msglen () ? _parameters
.out
.ret
: -1; }
77 ssize_t
rcvval () const { return _parameters
.out
.rcv
; }
80 #ifndef __INSIDE_CYGWIN__
83 int msgctl (struct thread
*, struct msgctl_args
*);
84 int msgget (struct thread
*, struct msgget_args
*);
85 int msgsnd (struct thread
*, struct msgsnd_args
*);
86 int msgrcv (struct thread
*, struct msgrcv_args
*);
89 #endif /* __CYGSERVER_MSG_H__ */