Function at 0x46cfa9
Capabilities:
Link many functions at runtime
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x38
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x1c], 0
mov dword [esp], str.WINICONV_LIBICONV_DLL
call sub.msvcrt.dll_getenv
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x46cfde
mov dword [ebp - 0x10], 0x6615ca
jmp 0x46d0ac
jmp 0x46d0ac
mov dword [esp + 4], 0x2c
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.msvcrt.dll_strchr
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x14]
jne 0x46d006
jmp 0x46d094
cmp dword [ebp - 0x14], 0
jne 0x46d01f
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.msvcrt.dll_strlen
mov edx, dword [ebp - 0x10]
add eax, edx
mov dword [ebp - 0x14], eax
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 0x10]
sub edx, eax
mov eax, edx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.0046cf43
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x46d04b
mov eax, 0
jmp 0x46d23e
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
call eax
sub esp, 4
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
call fcn.0062e160
cmp dword [ebp - 0xc], 0
je 0x46d094
mov eax, dword [0x6e5678]
cmp dword [ebp - 0xc], eax
jne 0x46d092
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_FreeLibrary]
call eax
sub esp, 4
mov dword [ebp - 0xc], 0
jmp 0x46d094
jmp 0x46d0ba
mov eax, dword [ebp - 0x14]
movzx eax, byte [eax]
cmp al, 0x2c
jne 0x46d0a6
mov eax, dword [ebp - 0x14]
add eax, 1
jmp 0x46d0a9
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
movzx eax, byte [eax]
test al, al
jne 0x46cfe3
cmp dword [ebp - 0xc], 0
jne 0x46d0c5
jmp 0x46d223
mov dword [esp + 4], str._errno
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call fcn.0046d2a2
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x46d0e6
jmp 0x46d223
mov dword [esp + 4], str.libiconv_open
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x46d122
mov dword [esp + 4], str.iconv_open
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov dword [ebp - 0x18], eax
mov dword [esp + 4], str.libiconv_close
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 4], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax + 4]
test eax, eax
jne 0x46d168
mov dword [esp + 4], str.iconv_close
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 4], eax
mov dword [esp + 4], str.libiconv
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 8], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax + 8]
test eax, eax
jne 0x46d1ae
mov dword [esp + 4], str.iconv
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 8], eax
mov dword [esp + 4], str._errno
mov eax, dword [ebp - 0x1c]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call eax
sub esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 0xc], eax
cmp dword [ebp - 0x18], 0
je 0x46d223
mov eax, dword [ebp + 8]
mov eax, dword [eax + 4]
test eax, eax
je 0x46d223
mov eax, dword [ebp + 8]
mov eax, dword [eax + 8]
test eax, eax
je 0x46d223
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0xc]
test eax, eax
je 0x46d223
mov eax, dword [ebp + 0x10]
mov dword [esp + 4], eax
mov eax, dword [ebp + 0xc]
mov dword [esp], eax
mov eax, dword [ebp - 0x18]
call eax
mov edx, dword [ebp + 8]
mov dword [edx], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax]
cmp eax, 0xffffffff
jne 0x46d213
jmp 0x46d223
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0xc]
mov dword [eax + 0x50], edx
mov eax, 1
jmp 0x46d23e
cmp dword [ebp - 0xc], 0
je 0x46d239
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_FreeLibrary]
call eax
sub esp, 4
mov eax, 0
leave
ret