freebsd5/sys/kern/subr_msgbuf.c
/*
 * Get a count of the number of unread characters in the message buffer.
 */
Get a count of the number of unread characters in the message buffer.
Get a count of the number of unread characters in the message buffer .
int
msgbuf_getcount(struct msgbuf *mbp)
{
	u_int len;
	len = MSGBUF_SEQSUB(mbp, mbp->msg_wseq, mbp->msg_rseq);
	if (len > mbp->msg_size)
		len = mbp->msg_size;
	return (len);
}
int msgbuf_getcount ( struct msgbuf * mbp ) { u_int len ; len = MSGBUF_SEQSUB ( mbp , mbp -> msg_wseq , mbp -> msg_rseq ) ; if ( len > mbp -> msg_size ) len = mbp -> msg_size ; return ( len ) ; }
Get a count of the number of unread characters in the message buffer.
Get a count of the number of unread characters in the message buffer .