Microsoft Internet Security and Acceleration Server 2000

Implement _CloseSockets and _GetSockets Functions

The function _CloseSockets is used by the data pump in the step Perform Data Pumping; _CloseSockets requires the function _GetSockets.

Implement _CloseSockets in SMTPDataFilter.cpp:

void CSMTPDataFilter::_CloseSockets(BOOL fAbortive)
	{
		CComPtr <IFWXSocket> spExternalSocket;
		CComPtr <IFWXSocket> spInternalSocket;
 
		OutputDebugString("\tCSMTPDataFilter::_CloseSockets\n");
 
		_GetSockets(&spInternalSocket,&spExternalSocket);
 
		if (spInternalSocket) 
					spInternalSocket->Close(fAbortive);
 
		spInternalSocket.Release();
 
		if (spExternalSocket)
					spExternalSocket->Close(fAbortive);
 
		spExternalSocket.Release();
}

Add the definition of the _CloseSockets function

void CSMTPDataFilter::_CloseSockets(BOOL fAbortive);

to the header file SMTPDataFilter.h in the private portion of the CSMTPDataFilter class.

Add the function _GetSockets to SMTPDataFilter.cpp:

	void CSMTPDataFilter::_GetSockets(IFWXSocket **ppInternalSocket,
					IFWXSocket **ppExternalSocket) 
	{
			Lock();
 
			//Get internal socket
		 *ppInternalSocket= m_spInternalSocket;
			if (*ppInternalSocket) 
		(*ppInternalSocket)->AddRef();
 
			//Get external socket
		 *ppExternalSocket= m_spExternalSocket;
			if (*ppExternalSocket) 
		(*ppExternalSocket)->AddRef();
 
			Unlock();
}

Add the definition of the _GetSockets function

void CSMTPDataFilter::_GetSockets(IFWXSocket **ppInternalSocket,
					IFWXSocket **ppExternalSocket);

to the header file SMTPDataFilter.h in the private portion of the CSMTPDataFilter class.

[an error occurred while processing this directive]