yw_conn_recv

Name

yw_conn_recv -- recive packet from peer

Synopsis


     #include <yw/sock.h>
   

YwPacket *yw_conn_recv(YwConnection *conn, int timeout);

DESCRIPTION

This function waits at most timeout miliseconds to fetch packet from conn. The returned packet has to be released using yw_packet_free(3), when it's no longer needed. If timeout is -1 yw_conn_recv() blocks until packet is recived or error occurs.

RETURN VALUE

The recived packet or NULL in case of error or timeout.

INFO

Generated from: recv.c,v 1.12 2001/05/11 10:38:05 malekith Exp.