/***************** send.c *****************/ #include #include #include #include #include #include #include #define NMSGS 5 extern int errno; struct msgbuf { long mtype; char mtext[100]; }; int main() { int msgid; int i, nloop; struct msgbuf msgp; char tmp_msg[100]; tmp_msg[0] = '\0'; msgid = msgget(9999, IPC_CREAT | 0666); if(msgid < 0) { printf("%d : Error number is %d\n", __LINE__, errno); exit(1); } for(nloop=0;nloop