📅  最后修改于: 2022-03-11 14:56:40.061000             🧑  作者: Mango
typedef struct Req
{
pid_t pid;
char data[4096];
} Req;
Req buf;
n = mq_receive(mqdes0, (char *) &buf, sizeof(buf), NULL);
mq_send(mqdes1, (const char *) &buf, sizeof(buf), 0);