Function at 0x4053f0
Capabilities:
Link many functions at runtime

Disassembly:
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedCompareExchange]
push 0
push 3
push 0x41ef58
call edi
mov esi, eax
cmp esi, 3
jne 0x405428
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
push 3
push 3
push 0x41ef58
call edi
push 0xa
mov esi, eax
call ebx
cmp esi, 3
je 0x405411
pop ebx
cmp esi, 1
je 0x4056cc
cmp esi, 2
je 0x4056d4
push str.TcApi.dll
mov edi, 2
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
mov dword [0x41ef5c], eax
je 0x4056f6
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.TcQueryPortList
push eax
call esi
mov dword [0x41ef60], eax
mov eax, dword [0x41ef5c]
push str.TcFreePortList
push eax
call esi
mov ecx, dword [0x41ef5c]
push str.TcStatusGetString
push ecx
mov dword [0x41ef64], eax
call esi
mov edx, dword [0x41ef5c]
push str.TcPortGetName
push edx
mov dword [0x41ef68], eax
call esi
mov dword [0x41ef6c], eax
mov eax, dword [0x41ef5c]
push str.TcPortGetDescription
push eax
call esi
mov ecx, dword [0x41ef5c]
push str.TcInstanceOpenByName
push ecx
mov dword [0x41ef70], eax
call esi
mov edx, dword [0x41ef5c]
push str.TcInstanceClose
push edx
mov dword [0x41ef74], eax
call esi
mov dword [0x41ef78], eax
mov eax, dword [0x41ef5c]
push str.TcInstanceSetFeature
push eax
call esi
mov ecx, dword [0x41ef5c]
push str.TcInstanceQueryFeature
push ecx
mov dword [0x41ef7c], eax
call esi
mov edx, dword [0x41ef5c]
push str.TcInstanceReceivePackets
push edx
mov dword [0x41ef80], eax
call esi
mov dword [0x41ef84], eax
mov eax, dword [0x41ef5c]
push str.TcInstanceGetReceiveWaitHandle
push eax
call esi
mov ecx, dword [0x41ef5c]
push str.TcInstanceTransmitPackets
push ecx
mov dword [0x41ef88], eax
call esi
mov edx, dword [0x41ef5c]
push str.TcInstanceQueryStatistics
push edx
mov dword [0x41ef8c], eax
call esi
mov dword [0x41ef90], eax
mov eax, dword [0x41ef5c]
push str.TcPacketsBufferCreate
push eax
call esi
mov ecx, dword [0x41ef5c]
push str.TcPacketsBufferDestroy
push ecx
mov dword [0x41ef94], eax
call esi
mov edx, dword [0x41ef5c]
push str.TcPacketsBufferQueryNextPacket
push edx
mov dword [0x41ef98], eax
call esi
mov dword [0x41ef9c], eax
push str.TcPacketsBufferCommitNextPacket
mov eax, dword [0x41ef5c]
push eax
call esi
mov ecx, dword [0x41ef5c]
push str.TcStatisticsDestroy
push ecx
mov dword [0x41efa0], eax
call esi
mov edx, dword [0x41ef5c]
push str.TcStatisticsUpdate
push edx
mov dword [0x41efa4], eax
call esi
mov dword [0x41efa8], eax
mov eax, dword [0x41ef5c]
push str.TcStatisticsQueryValue
push eax
call esi
mov ecx, dword [0x41ef60]
mov dword [0x41efac], eax
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef64]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef68]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef6c]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef70]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef74]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef78]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef7c]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef80]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef84]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef88]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef8c]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef90]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef94]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef98]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41ef9c]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41efa0]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41efa4]
test ecx, ecx
je 0x4056dc
mov ecx, dword [0x41efa8]
test ecx, ecx
je 0x4056dc
test eax, eax
je 0x4056dc
mov edi, 1
push edi
push 0x41ef58
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
mov eax, edi
pop edi
pop esi
ret
pop edi
mov eax, 1
pop esi
ret
pop edi
mov eax, 2
pop esi
ret
mov eax, dword [0x41ef5c]
test eax, eax
je 0x4056f6
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x41ef5c], 0
push edi
push 0x41ef58
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
mov eax, edi
pop edi
pop esi
ret