Updated: April 19, 2023 |
Determine whether a socket is at the out-of-band mark
#include <sys/socket.h> int sockatmark( int s );
The sockatmark() function determines whether the socket specified by s is at the out-of-band data mark. If the protocol for the socket supports out-of-band data by marking the stream with an out-of-band data mark, sockatmark() returns 1 when all data preceding the mark has been read and the out-of-band data mark is the first element in the receive queue.
The sockatmark() function doesn't remove the out-of-band data mark from the stream.
Using this function between receive operations lets an application determine which data comes before and after out-of-band data.
Safety: | |
---|---|
Cancellation point | No |
Interrupt handler | No |
Signal handler | No |
Thread | No |