LInet::AcceptConnect

#include "ltwrappr.h"

virtual L_INT LInet::AcceptConnect(plRemoteComp)

LInet * plRemoteComp;

/* remote computer class instance */

Accepts an incoming connection from a remote computer.

Parameter

Description

plRemoteComp

Address of the LInet object that contains the remote computer information.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

You must call LInet::ServerInit to get a valid LInet class object before any connections can be accepted using this function.

After this function returns, the plRemoteComp class object will be updated with the computer that was requesting the connection.

You can use LInet::GetHostName to see who is trying to connect to hHost, after you accept the connection, using this function. If you then wish to restrict access, you can disconnect plRemoteComp after examining the hostname.

You must initialize the LEADTOOLS Internet DLL using LInet::StartUp before calling this function.

Required DLLs and Libraries

LTNET

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

See Also

Functions:

LInet::ServerInit, LInet::Connect, LInet::Close, LInet::GetHostName, LInet::StartUp, LInet::ShutDown, Class Members

Topics:

Sending and Receiving Data

Example

For an example, refer to LInet::ServerInit.