Function at 0x46ff10
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x124
mov eax, dword [0x61900c]
xor eax, esp
mov dword [esp + 0x120], eax
push ebx
push esi
push edi
mov edi, ecx
mov eax, edx
mov dword [esp + 0x14], eax
cmp dword [edi], 0
jge 0x46ff7d
push str.connection_not_open_n
push 0xfffffffffffffffe
push 0x4f
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x224
push 2
call fcn.0048c22c
add esp, 4
push eax
call fcn.00401300
add esp, 0x1c
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x120]
xor ecx, esp
call fcn.0048485e
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x46ffac
push str.drain_
push 0
push 0
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x229
push 2
call fcn.0048c22c
add esp, 4
push eax
call fcn.00401300
add esp, 0x1c
imul eax, dword [0x61a648], 0x3e8
mov ebx, dword [sym.imp.WS2_32.dll_select]
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], eax
nop
mov eax, dword [edi]
mov dword [esp + 0x24], eax
mov dword [esp + 0x20], 1
nop
lea eax, [esp + 0x18]
push eax
push 0
push 0
lea eax, [esp + 0x2c]
push eax
mov eax, dword [edi]
inc eax
push eax
call ebx
test eax, eax
je 0x470149
cmp eax, 0xffffffff
jne 0x470044
call esi
cmp eax, 0x2714
je 0x470017
call esi
cmp eax, 0x2734
jne 0x47009e
push str.ser_drain__:_programmer_is_not_responding__reselecting_n
push 1
push 0x41
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x23d
push 2
call fcn.0048c22c
add esp, 4
push eax
call fcn.00401300
add esp, 0x1c
jmp 0x46ffe0
push 0
push 1
lea eax, [esp + 0x17]
push eax
push dword [edi]
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
js 0x47010d
cmp dword [esp + 0x14], 0
je 0x46ffd0
movzx eax, byte [esp + 0xf]
push eax
push str._02x
push 0
push 0
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x262
push 2
call fcn.0048c22c
add esp, 4
push eax
call fcn.00401300
add esp, 0x20
jmp 0x46ffd0
push 0
push 0
lea eax, [esp + 0x18]
push eax
push 0x400
call esi
push eax
push 0
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push dword [esp + 0x10]
push str.select__:__s_n
push 0xfffffffffffffffe
push 0x4f
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x24a
push 2
call fcn.0048c22c
add esp, 4
push eax
call fcn.00401300
add esp, 0x20
push dword [esp + 0x10]
call dword [sym.imp.KERNEL32.dll_LocalFree]
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x120]
xor ecx, esp
call fcn.0048485e
mov esp, ebp
pop ebp
ret
push 0
push 0
lea eax, [esp + 0x18]
push eax
push 0x400
call esi
push eax
push 0
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push dword [esp + 0x10]
push str.unable_to_read:__s_n
push 0xfffffffffffffffe
push 0x4f
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x25c
jmp 0x4700d8
cmp dword [esp + 0x14], 0
je 0x47017b
push str._drain_n
push 0
push 0
push str.net_drain
push str.D:_a_avrdude_avrdude_src_ser_win32.c
push 0x237
push 2
call fcn.0048c22c
add esp, 4
push eax
call fcn.00401300
add esp, 0x1c
mov ecx, dword [esp + 0x12c]
xor eax, eax
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0048485e
mov esp, ebp
pop ebp
ret