2004 by Marc J. Rochkind. All rights reserved. Portions marked "Open Source" may be copied under license.

 

Main Page   Modules   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

c7/smi_mq.c File Reference


Detailed Description

SMI - POSIX messages [Sec. 7.7.2].

Definition in file smi_mq.c.

Go to the source code of this file.

Compounds

struct  mq_attr
struct  SMIQ_MQ
struct  SMIQ_MQ::client_info

Defines

#define mq_open   (mqd_t)missing_function
#define mq_close(a)   missing_function(NULL)
#define mq_unlink   missing_function
#define mq_send(a, b, c, d)   missing_function(NULL)
#define mq_receive(a, b, c, d)   missing_function(NULL)
#define MAX_CLIENTS   20

Typedefs

typedef int mqd_t

Functions

int missing_function (const char *s,...)
void make_mq_name_server (const SMIQ_MQ *p, char *mqname, size_t mqname_max)
void make_mq_name_client (pid_t pid, char *mqname, size_t mqname_max)
mqd_t get_client_mqd (SMIQ_MQ *p, pid_t pid)
SMIQsmi_open_mq (const char *name, SMIENTITY entity, size_t msgsize)
bool smi_close_mq (SMIQ *sqp)
bool smi_send_getaddr_mq (SMIQ *sqp, struct client_id *client, void **addr)
bool smi_send_release_mq (SMIQ *sqp)
bool smi_receive_getaddr_mq (SMIQ *sqp, void **addr)
bool smi_receive_release_mq (SMIQ *sqp)

Variables

pid_t my_pid


Define Documentation

#define MAX_CLIENTS   20
 

Definition at line 51 of file smi_mq.c.

#define mq_close  )     missing_function(NULL)
 

Definition at line 44 of file smi_mq.c.

Referenced by smi_close_mq().

#define mq_open   (mqd_t)missing_function
 

Definition at line 43 of file smi_mq.c.

Referenced by get_client_mqd(), setup_posix_msg(), and smi_open_mq().

#define mq_receive a,
b,
c,
 )     missing_function(NULL)
 

Definition at line 47 of file smi_mq.c.

Referenced by smi_receive_getaddr_mq().

#define mq_send a,
b,
c,
 )     missing_function(NULL)
 

Definition at line 46 of file smi_mq.c.

Referenced by setup_posix_msg(), and smi_send_release_mq().

#define mq_unlink   missing_function
 

Definition at line 45 of file smi_mq.c.

Referenced by smi_close_mq(), and smi_open_mq().


Typedef Documentation

typedef int mqd_t
 

Definition at line 29 of file smi_mq.c.

Referenced by get_client_mqd(), Ux::PosixMsg::open(), setup_posix_msg(), smi_open_mq(), smi_receive_getaddr_mq(), and smi_send_release_mq().


Function Documentation

mqd_t get_client_mqd SMIQ_MQ p,
pid_t  pid
[static]
 

Definition at line 78 of file smi_mq.c.

References SMIQ_MQ::client_info::cl_mqd, SMIQ_MQ::client_info::cl_pid, EC_CLEANUP_BGN, EC_CLEANUP_END, ec_neg1, errno, make_mq_name_client(), MAX_CLIENTS, mq_open, mqd_t, SERVER_NAME_MAX, and SMIQ_MQ::sq_clients.

Referenced by smi_send_release_mq().

void make_mq_name_client pid_t  pid,
char *  mqname,
size_t  mqname_max
[static]
 

Definition at line 72 of file smi_mq.c.

Referenced by get_client_mqd(), smi_close_mq(), and smi_open_mq().

void make_mq_name_server const SMIQ_MQ p,
char *  mqname,
size_t  mqname_max
[static]
 

Definition at line 66 of file smi_mq.c.

References SMIQ_MQ::sq_name.

Referenced by smi_close_mq(), and smi_open_mq().

int missing_function const char *  s,
... 
[static]
 

Definition at line 37 of file smi_mq.c.

References errno.

bool smi_close_mq SMIQ sqp  ) 
 

Definition at line 144 of file smi_mq.c.

References make_mq_name_client(), make_mq_name_server(), mq_close, mq_unlink, my_pid, SERVER_NAME_MAX, SMI_SERVER, SMIQ_MQ::sq_entity, SMIQ_MQ::sq_mqd_server, and SMIQ_MQ::sq_msg.

Referenced by smi_open_mq().

SMIQ* smi_open_mq const char *  name,
SMIENTITY  entity,
size_t  msgsize
 

Definition at line 103 of file smi_mq.c.

References SMIQ_MQ::client_info::cl_mqd, EC_CLEANUP_BGN, EC_CLEANUP_END, ec_cmp, EC_FAIL, ec_neg1, ec_null, errno, getpid(), make_mq_name_client(), make_mq_name_server(), mq_attr::mq_maxmsg, mq_attr::mq_msgsize, mq_open, mq_unlink, mqd_t, my_pid, PERM_FILE, SERVER_NAME_MAX, smi_close_mq(), SMI_SERVER, SMIQ, SMIQ_MQ::sq_clients, SMIQ_MQ::sq_entity, SMIQ_MQ::sq_mqd_server, SMIQ_MQ::sq_msg, SMIQ_MQ::sq_msgsize, and SMIQ_MQ::sq_name.

bool smi_receive_getaddr_mq SMIQ sqp,
void **  addr
 

Definition at line 195 of file smi_mq.c.

References SMIQ_MQ::client_info::cl_mqd, EC_CLEANUP_BGN, EC_CLEANUP_END, ec_neg1, mq_receive, mqd_t, SMI_SERVER, SMIQ_MQ::sq_clients, SMIQ_MQ::sq_entity, SMIQ_MQ::sq_mqd_server, SMIQ_MQ::sq_msg, and SMIQ_MQ::sq_msgsize.

bool smi_receive_release_mq SMIQ sqp  ) 
 

Definition at line 215 of file smi_mq.c.

bool smi_send_getaddr_mq SMIQ sqp,
struct client_id *  client,
void **  addr
 

Definition at line 164 of file smi_mq.c.

References SMI_SERVER, SMIQ_MQ::sq_client, SMIQ_MQ::sq_entity, and SMIQ_MQ::sq_msg.

bool smi_send_release_mq SMIQ sqp  ) 
 

Definition at line 175 of file smi_mq.c.

References EC_CLEANUP_BGN, EC_CLEANUP_END, ec_neg1, get_client_mqd(), mq_send, mqd_t, my_pid, SMI_SERVER, SMIQ_MQ::sq_client, and SMIQ_MQ::sq_entity.


Variable Documentation

pid_t my_pid [static]
 

Definition at line 101 of file smi_mq.c.

Referenced by smi_close_mq(), smi_open_mq(), and smi_send_release_mq().


Generated on Fri Apr 23 10:57:09 2004 for AUP2 Example Source by doxygen 1.3.1