lgo_Listen()
Listen for a connection request from a remote system.
#include "laygo.h" LResult lgo_Listen ( LCid cid );
cid | connection to place in listening state |
lgo_Listen() initiates a wait for connection requests from remote systems. An unsuccessful return from lgo_Listen() means that no requests will be received from a remote system.
If a call to lgo_Listen() succeeds, the application may either cancel the listen request by calling lgo_ListenCancel() or poll for the receipt of a request from a remote system by calling lgo_Poll() or lgo_Event().
If successful, lgo_Listen() returns a non-negative value. Otherwise, it returns a negative value indicating the reason it failed. Possible unsuccessful return values are:
if (lgo_Listen(cid) < 0) { return (FAILURE); }