FLUSH SPREAD

FL_more_msgs

Section: User Manuals (3)
Updated: Dec 2000

NAME

FL_more_msgs - returns the number of complete messages buffered and ready to be received on a connection.

SYNOPSIS

#include <fl.h>

int FL_more_msgs(mailbox mbox);

DESCRIPTION

FL_more_msgs allows an application to check to see if any complete messages are already buffered and ready to be received on the connection represented by mbox.

NOTE, that this function CANNOT be used as an I/O polling function to check if a receive call should be done. If this function returns zero there still might be a message ready to receive on the connection: FL_poll, and file descriptor selects/polls can detect if there is activity (not necessarily a message) on a connection, while DONT_BLOCK receive semantics can detect whether or not there is a message on the connection and FL_more_msgs can only answer if there are any buffered messages already on the connection.

This function is merely a helper function to re-get the current status of the more_messes parameter returned from a call to FL_receive.

RETURN VALUES

Returns the number of complete buffered messages ready to be received, or one of the following errors ( < 0):
ILLEGAL_SESSION
The connection represented by mbox is illegal, usually because it is not active.

AUTHOR

John Schultz <jschultz@cnds.jhu.edu>