void Bind_Write_End(IAsyncResult ar)
{
Bind_SO stateObj = (Bind_SO)ar.AsyncState;
try
{
stateObj.UpdateContext();
NStream.EndWrite(ar);
//------------------------------------
// Read the response from proxy server.
//
NStream.BeginRead(
_response,
0,
8,
new AsyncCallback(Bind_Read_End),
stateObj);
}
catch(Exception e)
{
stateObj.Exception = e;
stateObj.SetCompleted();
}
}