All pastes #168659 Raw Edit

Anonymous

public text v1 · immutable
·published 2006-09-13 05:21 UTC
rendered paste body
        Case FD_WRITE
            DebugLog "Module2.WSAEventProxyRemote.FD_WRITE"
            Do
                tmpLength = Len(tvProxy(tmpIndex).tvLocalBuffer)
                If tmpLength = 0 Then
                    Exit Do
                End If
                If tmpLength > 1024 Then
                    tmpLength = 1024
                End If
                tmpBuffer = Mid$(tvProxy(tmpIndex).tvLocalBuffer, 1, tmpLength)
                tmpBufferB = StrConv(tmpBuffer, vbFromUnicode)
                If send(tvProxy(tmpIndex).tvRemoteSocket, tmpBufferB(0), UBound(tmpBufferB), 0) = SOCKET_ERROR Then
                    If tmpWSAError = 10035 Then
                        Exit Do
                    End If
                    DebugLog "Module2.WSAEventProxyRemote.FD_READ.send failed: " & WSAGetLastError
                    WSAProxyCleanup tmpIndex
                    Exit Sub
                End If
            Loop