【发布时间】:2014-06-09 05:00:41
【问题描述】:
我的服务器和客户端结构如下:
struct server
{
long msgtype;
char find[20];
};
struct client
{
long msgtype;
char text[200];
};
我使用 msgsnd() 函数将消息从客户端程序发送到公共消息队列。 我很难理解这句话
If msgtyp is greater than zero, the first message of **type** msgtyp is received.
type 是否意味着当我们使用 msgrcv() 函数时,收到的消息将是 long 类型(在这种情况下)。如果是这样,怎么可能收到一个很长的结构?
【问题讨论】: