Function at 0x46cca5
Capabilities:
Get common file path
Resolve function by parsing pe exports
Set current directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d12a9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x208
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x14], esi
mov edx, dword [esi + 0xc4]
mov ecx, dword [esi + 0xdc]
mov eax, dword [esi + 0xe0]
inc edx
inc ecx
mov dword [esi + 0xc4], edx
test eax, eax
mov dword [esi + 0xdc], ecx
jne 0x46ce93
mov ebx, dword [ebp + 8]
mov eax, dword [ebx + 0x2c]
mov dword [esi + 0xe0], eax
mov ecx, dword [ebx + 0x30]
mov dword [esi + 0xe4], ecx
mov edx, dword [ebx + 0x34]
mov ecx, dword [esi + 0x68]
lea eax, [esi + 0xf4]
inc edx
push eax
push ecx
mov dword [esi + 0xe8], edx
call fcn.004295a5
mov eax, dword [esi + 0x484]
add esp, 8
test eax, eax
jne 0x46cd44
push 0
call dword [sym.imp.ole32.dll_OleInitialize]
mov dword [esi + 0x484], 1
lea edx, [ebp - 0x214]
push 0x104
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x214]
push 0x5c
push eax
call fcn.004b0302
mov edi, eax
add esp, 8
test edi, edi
je 0x46cd88
lea edx, [ebp - 0x214]
lea ecx, [esi + 0xec]
push edx
mov byte [edi], 0
call fcn.004c45bc
inc edi
push edi
jmp 0x46cd9a
lea ecx, [esi + 0xec]
call fcn.004c440a
lea eax, [ebp - 0x214]
push eax
lea ecx, [esi + 0xf0]
call fcn.004c45bc
cmp dword [ebx + 0x2c], 2
je 0x46cdba
mov eax, dword [esi + 0xec]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
jmp 0x46ce06
lea ecx, [ebp - 0x214]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
lea edi, [ebp - 0x214]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffe
lea eax, [ebp + ecx - 0x214]
mov cl, byte [ebp + ecx - 0x214]
cmp cl, 0x5c
jne 0x46cdf4
mov byte [eax], 0
lea edx, [ebp - 0x214]
lea ecx, [esi + 0xec]
push edx
call fcn.004c45bc
mov eax, dword [esi + 0x68]
push 0x5724fe
push eax
lea ecx, [esi + 0x3fc]
call fcn.00426e05
mov ecx, dword [esi + 0x68]
push str.odbcdb
push ecx
lea ecx, [esi + 0x40c]
call fcn.00426e05
mov edx, dword [esi + 0x68]
push str.cominf
push edx
lea ecx, [esi + 0x43c]
call fcn.00426e05
xor edi, edi
push 0x7f00
push edi
call dword [sym.imp.USER32.dll_LoadCursorA]
push edi
push edi
push edi
push edi
push edi
push edi
push edi
push edi
push 0x57a8ce
push edi
push 5
mov dword [ebp - 0x30], eax
call dword [sym.imp.GDI32.dll_GetStockObject]
push eax
mov eax, dword [ebp - 0x30]
push eax
push edi
call fcn.004c1eca
push eax
push 0x80
lea ecx, [esi + 0x448]
call fcn.004c17e5
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [esi + 0x2b4], eax
jmp 0x46ceae
mov ebx, dword [ebp + 8]
mov eax, dword [esi + 0xe8]
mov ecx, dword [ebx + 0x34]
cmp eax, ecx
ja 0x46cea5
mov eax, ecx
inc eax
xor edi, edi
mov dword [esi + 0xe8], eax
mov eax, dword [ebx + 0x48]
mov dword [ebp - 0x68], edi
cmp eax, 0xffffffff
mov dword [ebp - 0x64], edi
mov dword [ebp - 0x60], edi
mov dword [ebp - 0x5c], edi
je 0x46cef1
mov edi, dword [eax + ebx + 0x2c]
add edi, ebx
mov dword [ebp - 0x68], edi
mov eax, dword [eax + ebx + 0x24]
cmp eax, 0x34
jb 0x46ced9
mov eax, 0x34
mov ecx, eax
mov esi, 0x571716
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [ebp - 0x14]
mov eax, dword [esi + 0xdc]
lea ecx, [esi + 0x218]
push eax
call fcn.0043d5b5
mov eax, dword [ebx + 0x40]
cmp eax, 0xffffffff
mov dword [ebp - 0x1c], eax
je 0x46cf3a
mov edi, dword [eax + ebx + 0x2c]
lea ecx, [esi + 0x204]
add edi, ebx
push edi
call fcn.0043d5b5
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ecx + ebx + 0x24]
lea ecx, [esi + 0x204]
add eax, edi
push eax
call fcn.0043d5b5
mov dword [ebp - 0x64], edi
jmp 0x46cf52
lea edi, [esi + 0x204]
push 0
mov ecx, edi
call fcn.0043d5b5
push 0
mov ecx, edi
call fcn.0043d5b5
mov eax, dword [ebx + 0x4c]
mov dword [ebp - 0x3c], 0
cmp eax, 0xffffffff
je 0x46cf6d
mov eax, dword [eax + ebx + 0x2c]
add eax, ebx
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x5c], eax
mov eax, dword [ebx + 0x50]
cmp eax, 0xffffffff
mov dword [ebp - 0x28], eax
je 0x46cfd8
mov eax, dword [eax + ebx + 0x24]
test eax, eax
jle 0x46cfd8
push eax
call fcn.004c0d42
mov edx, dword [ebp - 0x28]
mov edi, eax
xor eax, eax
mov dword [ebp - 0x1c], edi
mov ecx, dword [edx + ebx + 0x24]
add esp, 4
mov edx, ecx
add esi, 0xf8
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov eax, dword [ebp - 0x1c]
mov ecx, esi
push eax
call fcn.0043d5b5
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 0x60], eax
mov esi, dword [ecx + ebx + 8]
mov edx, dword [ecx + ebx + 0x24]
and esi, 0xffffffef
sub eax, ebx
mov dword [ecx + ebx + 0x28], edx
mov dword [ecx + ebx + 8], esi
mov dword [ecx + ebx + 0x2c], eax
mov ebx, dword [ebx + 0x54]
mov dword [ebp - 0x38], 0
cmp ebx, 0xffffffff
mov dword [ebp - 0x18], ebx
je 0x46d0ad
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 8]
push str._reloc1
mov esi, dword [ecx + eax + 0x2c]
mov edx, dword [ecx + eax + 4]
lea ebx, [ecx + eax]
add esi, eax
mov dword [ebp - 0x18], edx
lea eax, [ebx + 0xc]
push eax
call fcn.004aff13
add esp, 8
test eax, eax
jne 0x46d01c
mov dword [ebp - 0x38], esi
test byte [ebx + 8], 0x10
je 0x46d07a
mov eax, dword [ebx + 0x24]
mov ecx, dword [ebx + 0x28]
cmp eax, ecx
jle 0x46d07a
push eax
call fcn.004c0d42
mov ecx, dword [ebx + 0x28]
mov edx, eax
mov eax, ecx
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
add esp, 4
rep movsb byte es:[edi], byte [esi]
mov esi, dword [ebx + 0x28]
mov ecx, dword [ebx + 0x24]
sub ecx, esi
push edx
lea edi, [esi + edx]
mov esi, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, esi
mov dword [ebp - 0x30], edx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [ebp - 0x14]
add ecx, 0xf8
call fcn.0043d5b5
mov esi, dword [ebp - 0x30]
mov eax, dword [ebx + 0x30]
xor edx, edx
test eax, eax
lea edi, [ebx + 0x38]
jle 0x46d0a3
mov eax, dword [edi]
add edi, 4
mov ecx, eax
and eax, 7
shr ecx, 3
mov eax, dword [ebp + eax*4 - 0x68]
add ecx, esi
add dword [ecx], eax
mov eax, dword [ebx + 0x30]
inc edx
cmp edx, eax
jl 0x46d086
cmp dword [ebp - 0x18], 0xffffffff
jne 0x46cfee
mov ebx, dword [ebp - 0x14]
mov eax, dword [ebx + 0x160]
shr eax, 2
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 8]
lea edi, [eax + 0x58]
mov eax, dword [eax + 0x38]
test eax, eax
mov dword [ebp - 0x20], eax
jle 0x46d1d9
mov ecx, dword [ebp - 0x20]
mov eax, dword [ebx + 0x1ec]
shr eax, 2
lea esi, [ecx*4]
lea ecx, [ebx + 0x1dc]
push esi
push 0
mov dword [ebp - 0x18], eax
call fcn.0043da55
push esi
push 0
lea ecx, [ebx + 0x1f0]
call fcn.0043da55
lea ecx, [ebx + 0x1b4]
push esi
push 0
mov dword [ebp - 0x24], ecx
call fcn.0043da55
lea ecx, [ebx + 0x1c8]
push esi
push 0
mov dword [ebp - 0x30], ecx
call fcn.0043da55
mov eax, dword [ebp - 0x20]
mov edx, dword [ebp - 0x64]
test eax, eax
mov dword [ebp - 0x28], edx
jle 0x46d16c
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x1c], eax
lea edx, [ecx*4]
mov eax, dword [edi]
mov ebx, dword [ebp - 0x28]
add eax, ebx
test ecx, ecx
jl 0x46d15c
mov esi, dword [ebp - 0x24]
mov ebx, dword [esi + 0x10]
shr ebx, 2
cmp ecx, ebx
jge 0x46d15c
mov esi, dword [esi + 8]
mov dword [esi + edx], eax
mov eax, dword [ebp - 0x1c]
add edx, 4
inc ecx
add edi, 4
dec eax
mov dword [ebp - 0x1c], eax
jne 0x46d13e
mov eax, dword [ebp - 0x20]
test eax, eax
jle 0x46d1aa
mov ecx, dword [ebp - 0x18]
mov esi, eax
lea edx, [ecx*4]
mov eax, dword [edi]
mov ebx, dword [ebp - 0x28]
add eax, ebx
test ecx, ecx
jl 0x46d1a0
mov ebx, dword [ebp - 0x30]
mov ebx, dword [ebx + 0x10]
shr ebx, 2
cmp ecx, ebx
jge 0x46d1a0
mov ebx, dword [ebp - 0x30]
mov ebx, dword [ebx + 8]
mov dword [ebx + edx], eax
add edx, 4
inc ecx
add edi, 4
dec esi
jne 0x46d17f
mov ebx, dword [ebp - 0x18]
test ebx, ebx
jle 0x46d1d9
mov eax, dword [ebp - 0x38]
test eax, eax
je 0x46d1d9
mov ecx, dword [eax]
mov edx, dword [eax + ecx*4 + 4]
lea ecx, [eax + ecx*4 + 4]
add ecx, 4
test edx, edx
jle 0x46d1d9
mov esi, dword [ebp - 0x3c]
mov eax, dword [ecx]
add dword [eax + esi], ebx
add eax, esi
add ecx, 4
dec edx
jne 0x46d1cc
mov al, byte [edi]
xor ebx, ebx
test al, al
mov dword [ebp - 0x24], edi
mov esi, edi
je 0x46d33a
push esi
inc ebx
call fcn.0043dd75
add esi, eax
add esp, 4
cmp byte [esi], 0
jne 0x46d1ea
test ebx, ebx
jle 0x46d33a
mov ecx, dword [ebp - 0x14]
lea esi, [ebx*4]
push esi
push 0
add ecx, 0x18c
call fcn.0043da55
mov edx, dword [ebp - 0x14]
push esi
push 0
lea ecx, [edx + 0x164]
call fcn.0043da55
mov eax, dword [ebp - 0x14]
push esi
push 0
lea ecx, [eax + 0x150]
call fcn.0043da55
mov ecx, dword [ebp - 0x14]
push esi
push 0
add ecx, 0x178
call fcn.0043da55
mov esi, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x14]
add ebx, esi
push 0xffffffffffffffff
push ebx
lea ecx, [edx + 0x1a0]
call fcn.004c0240
cmp byte [edi], 0
je 0x46d295
mov edi, dword [ebp - 0x24]
mov ebx, dword [ebp - 0x14]
mov eax, esi
push 0
push eax
push edi
mov ecx, ebx
inc esi
call fcn.00469d05
test eax, eax
je 0x46d934
push edi
call fcn.0043dd75
add edi, eax
add esp, 4
cmp byte [edi], 0
jne 0x46d26f
mov ebx, dword [ebp - 0x2c]
test ebx, ebx
jle 0x46d33a
mov ecx, dword [ebp - 0x38]
test ecx, ecx
je 0x46d33a
mov esi, dword [ecx]
add ecx, 4
mov eax, 2
lea ecx, [ecx + esi*4]
mov esi, dword [ecx]
add ecx, 4
dec eax
jne 0x46d2b5
test esi, esi
jle 0x46d2e6
mov edi, ecx
mov dword [ebp - 0x30], esi
mov eax, dword [edi]
mov edx, dword [ebp - 0x3c]
add eax, edx
mov edx, dword [eax]
test edx, edx
je 0x46d2da
add edx, ebx
mov dword [eax], edx
mov eax, dword [ebp - 0x30]
add edi, 4
dec eax
mov dword [ebp - 0x30], eax
jne 0x46d2c9
mov eax, dword [ecx + esi*4]
lea ecx, [ecx + esi*4]
add ecx, 4
test eax, eax
jle 0x46d33a
mov edi, ecx
mov dword [ebp - 0x30], eax
mov ecx, dword [edi]
mov esi, dword [ebp - 0x3c]
add ecx, esi
mov eax, dword [ecx]
mov esi, eax
and eax, 0xdfffffff
mov edx, eax
and esi, 0x20000000
shr edx, 0x10
cmp edx, 1
jle 0x46d32e
add edx, ebx
and eax, 0xffff
and edx, 0xffff
shl edx, 0x10
or edx, eax
or edx, esi
mov dword [ecx], edx
mov eax, dword [ebp - 0x30]
add edi, 4
dec eax
mov dword [ebp - 0x30], eax
jne 0x46d2f8
mov edi, dword [ebp + 8]
mov esi, dword [edi + 0x44]
cmp esi, 0xffffffff
je 0x46d8ae
lea ecx, [ebp - 0x50]
call fcn.0043d2b5
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x58], 0x4e20c8
mov dword [ebp - 0x54], eax
xor ebx, ebx
lea ecx, [ebp - 0x34]
mov dword [ebp - 4], ebx
call fcn.004c0ccc
push 0x400
lea ecx, [ebp - 0xcc]
mov byte [ebp - 4], 2
call fcn.004c8a01
mov edx, dword [esi + edi + 0x2c]
mov ecx, dword [esi + edi + 0x28]
push ebx
add edx, edi
push ecx
push edx
lea ecx, [ebp - 0xcc]
mov byte [ebp - 4], 3
call fcn.004c8a4d
push ebx
push 0x1000
lea eax, [ebp - 0xcc]
push 1
push eax
lea ecx, [ebp - 0x110]
call fcn.004c8167
lea ecx, [ebp - 0x110]
mov byte [ebp - 4], 4
push ecx
lea ecx, [ebp - 0x58]
call fcn.00465c45
lea ecx, [ebp - 0x110]
call fcn.004c82cb
lea ecx, [ebp - 0x110]
mov byte [ebp - 4], 3
call fcn.004c8243
lea ecx, [ebp - 0xcc]
mov byte [ebp - 4], 2
call fcn.004c8a8a
mov dword [ebp - 4], ebx
call fcn.004c0d0a
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x5c]
mov ecx, eax
mov dword [ebp - 0x30], edx
mov edx, dword [ebp - 0x48]
mov dword [ebp - 0x20], ebx
shr ecx, 3
neg eax
sbb eax, eax
mov dword [ebp - 0x1c], ecx
and eax, edx
cmp ecx, ebx
lea eax, [eax + ecx*4]
mov dword [ebp - 0x18], eax
jle 0x46d53c
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x20]
xor ebx, ebx
mov eax, dword [ecx + edx*4]
mov dword [ebp - 0x28], eax
mov eax, dword [eax + 0x18]
test eax, eax
mov dword [ebp - 0x24], eax
jle 0x46d52a
mov eax, dword [ebp - 0x28]
push 0
push ebx
lea edi, [eax + 0x14]
mov ecx, edi
call fcn.00464945
mov esi, eax
mov eax, dword [ebp - 0x2c]
test eax, eax
jle 0x46d47c
mov eax, dword [esi]
mov ecx, eax
shr ecx, 0x10
cmp ecx, 1
jle 0x46d47c
mov edx, dword [ebp - 0x2c]
and eax, 0xffff
add ecx, edx
and ecx, 0xffff
shl ecx, 0x10
or ecx, eax
mov dword [esi], ecx
push ebx
mov ecx, edi
call fcn.00465235
cmp eax, 1
jne 0x46d4c1
add esi, 0x18
push esi
call fcn.0043dd75
add esi, eax
push esi
call fcn.0043dd75
lea esi, [esi + eax + 0xc]
push esi
call fcn.0043dd75
add esi, eax
add esp, 0xc
mov eax, dword [esi]
cmp eax, 0xffffffff
je 0x46d4b9
mov ecx, dword [ebp - 0x30]
add eax, ecx
mov dword [esi], eax
jmp 0x46d51e
mov dword [esi], 0
jmp 0x46d51e
add esi, 0x18
push esi
call fcn.0043dd75
add esi, eax
push esi
call fcn.0043dd75
mov edx, dword [esi + eax + 0x1c]
lea esi, [esi + eax + 0x1c]
mov ecx, dword [esi + edx*4 + 4]
lea eax, [esi + edx*4 + 4]
lea esi, [ecx + eax + 4]
push esi
call fcn.0043dd75
mov ecx, dword [eax + esi + 0xc]
lea eax, [eax + esi + 0xc]
add esp, 0xc
add eax, 8
xor edx, edx
test ecx, ecx
jle 0x46d51e
mov esi, dword [eax]
cmp esi, 0xffffffff
je 0x46d510
mov edi, dword [ebp - 0x30]
add esi, edi
mov dword [eax], esi
jmp 0x46d516
mov dword [eax], 0
add eax, 8
inc edx
cmp edx, ecx
jl 0x46d500
mov eax, dword [ebp - 0x24]
inc ebx
cmp ebx, eax
jl 0x46d440
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x1c]
inc eax
cmp eax, ecx
mov dword [ebp - 0x20], eax
jl 0x46d424
mov eax, dword [ebp - 0x38]
test eax, eax
je 0x46d84f
mov edx, dword [ebp - 0x14]
mov eax, dword [edx + 0x14c]
shr eax, 3
test eax, eax
jle 0x46d84f
lea ecx, [ebp - 0x7c]
call fcn.0043d2b5
mov esi, 0x4dce54
mov dword [ebp - 0x7c], esi
lea ecx, [ebp - 0x90]
call fcn.0043d2b5
mov dword [ebp - 0x90], esi
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x40]
mov esi, dword [ebp - 0x48]
mov byte [ebp - 4], 9
mov ebx, dword [eax]
lea edx, [eax + 4]
mov eax, ecx
mov dword [ebp - 0x24], edx
neg eax
sbb eax, eax
and eax, esi
lea esi, [ebp - 0x90]
push esi
lea esi, [ebp - 0x7c]
shr ecx, 3
push esi
push ecx
mov ecx, dword [ebp - 0x14]
push eax
mov eax, dword [ebp - 0x3c]
push ebx
push edx
push eax
call fcn.0046cc25
mov eax, dword [ebp - 0x40]
mov ecx, dword [ebp - 0x48]
mov esi, eax
shr esi, 3
neg eax
sbb eax, eax
xor edi, edi
and eax, ecx
mov dword [ebp - 0x1c], esi
test esi, esi
lea ecx, [eax + esi*4]
mov dword [ebp - 0x18], ecx
jle 0x46d611
mov edx, dword [ebp - 0x18]
mov eax, dword [edx + edi*4]
mov edx, dword [eax + 0x2c]
mov ecx, dword [eax + 0x18]
test edx, edx
jne 0x46d5eb
xor eax, eax
jmp 0x46d5ee
mov eax, dword [eax + 0x24]
lea edx, [ebp - 0x90]
push edx
lea edx, [ebp - 0x7c]
push edx
push ecx
mov ecx, dword [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x24]
push ebx
push eax
push ecx
mov ecx, dword [ebp - 0x14]
call fcn.0046cc25
inc edi
cmp edi, esi
jl 0x46d5d7
test esi, esi
mov dword [ebp - 0x20], 0
jle 0x46d826
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x2c], 0
mov ecx, dword [edx + eax*4]
mov dword [ebp - 0x28], ecx
lea ecx, [ebp - 0xa4]
call fcn.0043d2b5
mov eax, dword [ebp - 0x80]
mov byte [ebp - 4], 0xa
shr eax, 2
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x28]
mov eax, ecx
inc ecx
lea edi, [edx + 0x14]
mov dword [ebp - 0x2c], ecx
push 0
push eax
mov ecx, edi
call fcn.00464945
mov ebx, eax
test ebx, ebx
je 0x46d7fb
mov esi, dword [ebx]
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x38]
push eax
push esi
call fcn.00469665
test eax, eax
je 0x46d739
test dword [eax + 0x14], 0x2000000
je 0x46d739
and esi, 0xffff
lea ecx, [ebp - 0xb8]
dec esi
push ecx
push ebx
mov ecx, edi
mov dword [ebp - 0xc0], esi
call fcn.00465255
mov edx, dword [ebp - 0x6c]
mov esi, dword [ebp - 0x74]
mov ecx, dword [ebp - 0x88]
mov dword [ebp - 0xbc], eax
mov eax, dword [ebp - 0x80]
push 0
neg edx
sbb edx, edx
mov dword [ebp - 0x94], 0
and edx, esi
neg eax
sbb eax, eax
mov dword [ebp - 0xb4], edx
and eax, ecx
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0xb0], eax
lea eax, [ebp - 0xc0]
mov dword [ebp - 0xac], ecx
mov ecx, dword [ebp - 0x38]
lea edx, [ebp - 0xa4]
push eax
push 9
mov dword [ebp - 0xa8], edx
call dword [ecx + 0x78]
test eax, eax
je 0x46d739
mov ecx, dword [ebp - 0x94]
mov esi, dword [ebp - 0x9c]
mov edx, dword [ebp - 0x2c]
mov eax, ecx
neg eax
sbb eax, eax
push ecx
and eax, esi
dec edx
push eax
push edx
mov ecx, edi
call fcn.00464995
push eax
mov ecx, edi
call fcn.004652d5
mov eax, dword [ebp - 0x2c]
mov ecx, edi
dec eax
push eax
call fcn.00465235
test eax, eax
jne 0x46d64b
lea esi, [ebx + 0x18]
push esi
call fcn.0043dd75
add esi, eax
push esi
call fcn.0043dd75
mov ecx, dword [eax + esi + 0x18]
lea esi, [eax + esi + 0x18]
add esp, 8
test ecx, ecx
je 0x46d7a1
mov eax, dword [ebp - 0x6c]
test eax, eax
je 0x46d79b
mov edx, dword [ebp - 0x74]
test edx, edx
je 0x46d79b
shr eax, 2
push ecx
push eax
push edx
call fcn.0043de05
add esp, 0xc
cmp eax, 0xffffffff
je 0x46d79b
mov ecx, dword [ebp - 0x88]
mov edx, dword [ecx + eax*4]
mov dword [esi], edx
jmp 0x46d7a1
mov dword [esi], 0
mov ebx, dword [esi + 4]
add esi, 4
add esi, 4
xor edi, edi
test ebx, ebx
jle 0x46d64b
mov ecx, dword [esi]
test ecx, ecx
je 0x46d7ee
mov eax, dword [ebp - 0x6c]
test eax, eax
je 0x46d7e8
mov edx, dword [ebp - 0x74]
test edx, edx
je 0x46d7e8
shr eax, 2
push ecx
push eax
push edx
call fcn.0043de05
add esp, 0xc
cmp eax, 0xffffffff
je 0x46d7e8
mov ecx, dword [ebp - 0x88]
mov edx, dword [ecx + eax*4]
mov dword [esi], edx
jmp 0x46d7ee
mov dword [esi], 0
add esi, 4
inc edi
cmp edi, ebx
jl 0x46d7b4
jmp 0x46d64b
lea ecx, [ebp - 0xa4]
mov byte [ebp - 4], 9
mov dword [ebp - 0xa4], 0x4dce38
call fcn.0043d4b5
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x1c]
inc eax
cmp eax, ecx
mov dword [ebp - 0x20], eax
jl 0x46d620
mov esi, 0x4dce38
lea ecx, [ebp - 0x90]
mov byte [ebp - 4], 8
mov dword [ebp - 0x90], esi
call fcn.0043d4b5
lea ecx, [ebp - 0x7c]
mov byte [ebp - 4], 0
mov dword [ebp - 0x7c], esi
call fcn.0043d4b5
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x58]
push eax
add ecx, 0x134
call fcn.004651b5
lea ecx, [ebp - 0x50]
call fcn.0043d4b5
mov dword [ebp - 0x58], 0x4e20c8
lea ecx, [ebp - 0x58]
mov dword [ebp - 4], 0xb
call fcn.00465b85
mov dword [ebp - 0x58], 0x4e20d4
lea ecx, [ebp - 0x50]
mov dword [ebp - 4], 0xc
call fcn.0043d4b5
lea ecx, [ebp - 0x50]
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x50], 0x4dce38
call fcn.0043d4b5
mov edi, dword [ebp + 8]
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax + 0x188]
test ecx, ecx
jne 0x46d94a
mov dword [0x57ae9e], 0
jmp 0x46d955
or eax, 0xffffffff
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [eax + 0x180]
mov dword [0x57ae9e], eax
cmp dword [edi + 0x2c], 2
jne 0x46d962
lea eax, [ebp - 0x68]
int3
mov eax, dword [edi + 0x3c]
mov ecx, dword [ebp - 0xc]
add eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 4