Function at 0x4d2050
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x78
mov edi, dword [ebp + 0xc]
mov ebx, edx
mov dword [esp + 0x18], ecx
mov dword [esp + 8], edx
mov esi, dword [edi + 0x10]
test esi, esi
je 0x4d21de
lea eax, [esi - 1]
cmp dword [edi + 0xc], eax
jbe 0x4d21de
mov ecx, dword [edi + 8]
test ecx, ecx
je 0x4d21de
movzx eax, byte [ecx + eax]
mov ecx, dword [ebx + 0x258]
mov edx, dword [ebx + 0x260]
or edx, dword [ebx + 0x270]
or ecx, dword [ebx + 0x268]
mov byte [esp + 0x24], al
mov eax, dword [ebx + 0x264]
or ecx, edx
mov edx, dword [ebx + 0x25c]
or eax, dword [ebx + 0x274]
or edx, dword [ebx + 0x26c]
or edx, eax
movzx eax, byte [esp + 0x24]
or edx, ecx
mov ecx, dword [edi + 4]
mov edx, dword [edi]
mov edi, dword [ebp + 8]
mov dword [esp + 0x14], eax
mov dword [esp], ecx
je 0x4d2228
mov ch, byte [esp + 0x24]
mov dword [esp + 0x70], 0
mov dword [esp + 0x6c], 0
mov dword [esp + 0x68], 0
mov dword [esp + 0x64], 1
mov dword [esp + 0x60], 0
mov dword [esp + 0x5c], 0
mov dword [esp + 0x58], 0
mov dword [esp + 0x54], 0
mov al, ch
and ch, 7
and al, 0x78
mov cl, ch
shr al, 3
neg al
movsx eax, al
mov dword [esp + 4], eax
mov ebx, dword [esp + eax + 0x6c]
mov eax, dword [esp + eax + 0x70]
shld eax, ebx, cl
shl ebx, cl
not cl
mov dword [esp + 0x10], eax
mov eax, dword [esp + 4]
mov eax, dword [esp + eax + 0x68]
mov dword [esp + 0xc], edx
mov edx, eax
mov edi, eax
mov eax, dword [esp + 0x14]
shr edx, 1
shr edx, cl
mov cl, ch
or edx, ebx
mov ebx, dword [esp + 4]
shr eax, 3
and eax, 0xfffffff0
mov ebx, dword [esp + ebx + 0x64]
shld edi, ebx, cl
shl ebx, cl
mov ecx, dword [esp + 8]
mov dword [esp + 0x48], edi
add ecx, 0x258
mov dword [esp + 4], ecx
and edx, dword [ecx + eax + 8]
mov ecx, dword [esp + 0x10]
mov edi, dword [esp + 4]
and ecx, dword [edi + eax + 0xc]
mov edi, dword [esp + 0x48]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 4]
and edi, dword [ecx + eax + 4]
and ebx, dword [ecx + eax]
or edi, dword [esp + 0x10]
or ebx, edx
mov edx, dword [esp + 0xc]
or edi, ebx
mov ebx, dword [esp + 8]
mov edi, dword [ebp + 8]
je 0x4d2228
movzx eax, byte [esp + 0x24]
mov dword [esp + 0x28], 4
mov byte [esp + 0x2c], al
jmp 0x4d2267
mov eax, dword [edi + 4]
mov edx, dword [edi]
mov edi, dword [ebp + 8]
mov dword [esp], eax
mov al, 2
movzx ecx, al
test edx, edx
je 0x4d2238
cmp edx, 1
jne 0x4d220d
add ecx, 6
mov dword [esp + 0xc], edx
mov edx, dword [edi + 0x88]
cmp ecx, edx
jb 0x4d224a
jmp 0x4d254d
test byte [ebx + 0x51], 1
jne 0x4d251c
mov eax, dword [esp]
mov dword [esp + 0x28], 2
mov dword [esp + 0x2c], eax
jmp 0x4d2267
mov eax, dword [esp + 0x14]
movzx eax, byte [ebx + eax + 0x58]
movzx ecx, al
test edx, edx
jne 0x4d21f2
mov dword [esp + 0xc], edx
mov edx, dword [edi + 0x88]
cmp ecx, edx
jae 0x4d254d
mov edx, dword [edi + 0x84]
mov edx, dword [edx + ecx*4]
test edx, edx
js 0x4d2603
mov dword [esp + 0x2c], edx
mov dword [esp + 0x28], 5
lea ebx, [esp + 0x28]
lea ecx, [esp + 0x30]
mov edx, ebx
push esi
call fcn.00487ac0
add esp, 4
cmp dword [esp + 0x30], 0
mov edi, dword [esp + 0x34]
je 0x4d22bd
mov dword [esp + 0x50], edi
movzx eax, byte [edi]
test eax, eax
je 0x4d2299
cmp eax, 1
jne 0x4d2897
mov esi, dword [edi + 4]
push edi
push 0
push dword [0x5a1188]
call dword [sym.imp.kernel32.dll_HeapFree]
mov eax, dword [esp + 0x18]
mov dword [eax + 4], esi
mov dword [eax], 2
jmp 0x4d2837
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 0x14]
mov ebx, dword [ecx + 0xc]
cmp esi, edx
mov dword [esp], edx
mov dword [esp + 0x20], ebx
jae 0x4d245e
mov eax, dword [ecx + 8]
mov dword [esp + 0x10], 0
mov dword [esp + 0x24], eax
mov eax, dword [esp + 8]
mov edx, dword [eax + 0x278]
mov eax, dword [eax + 0x27c]
and eax, 0x1f
cmp ebx, esi
mov dword [esp + 0x48], edx
mov dword [esp + 0x4c], eax
movzx eax, byte [ecx + 0x18]
mov byte [esp + 0x1f], al
mov eax, esi
cmova eax, ebx
mov ebx, dword [ebp + 8]
mov dword [esp + 0xc], eax
jmp 0x4d232c
mov edx, dword [esp]
inc esi
cmp edx, esi
je 0x4d2557
cmp dword [esp + 0xc], esi
je 0x4d2861
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 8]
movzx eax, byte [eax + esi]
movzx edx, byte [ecx + eax + 0x158]
mov ecx, edi
and ecx, 0x7ffffff
add ecx, edx
mov edx, dword [ebx + 0x7c]
cmp ecx, edx
jae 0x4d2857
mov edx, dword [ebx + 0x78]
mov edx, dword [edx + ecx*4]
test edx, edx
js 0x4d242c
mov edi, edx
cmp edx, 0x7ffffff
jbe 0x4d2320
mov edx, dword [esp]
test edi, 0x8000000
jne 0x4d23a0
test edi, 0x40000000
jne 0x4d2670
test edi, 0x20000000
je 0x4d2323
jmp 0x4d2452
mov eax, dword [esp + 0x48]
mov dword [esp + 0x14], 0
cmp dword [eax + 0x154], 1
je 0x4d2410
mov eax, ebx
mov ebx, edi
mov ecx, dword [esp + 0x4c]
mov edx, dword [eax + 0x94]
and ebx, 0x7ffffff
shr ebx, cl
cmp ebx, edx
jae 0x4d2873
mov ecx, dword [eax + 0x90]
mov edx, dword [esp]
mov eax, dword [ecx + ebx*8 + 4]
test eax, eax
je 0x4d287f
mov ecx, dword [ecx + ebx*8]
mov ebx, dword [ebp + 8]
test byte [ecx + 8], 2
je 0x4d2410
cmp eax, 0xd
jb 0x4d28d9
add eax, 0xfffffff3
cmp eax, 3
jbe 0x4d28ea
mov eax, dword [ecx + 0x15]
mov dword [esp + 0x14], eax
cmp byte [esp + 0x1f], 0
mov dword [esp + 0x10], 1
jne 0x4d268f
mov dword [esp + 4], esi
jmp 0x4d2323
mov ecx, dword [esp + 8]
shl eax, 8
mov edx, edi
mov dword [esp + 0x30], ecx
mov dword [esp + 0x34], ebx
lea ecx, [esp + 0x30]
push eax
call fcn.00535080
add esp, 4
test eax, eax
je 0x4d236d
movzx eax, byte [0x5a11e8]
jmp 0x4d22ab
mov ebx, dword [ebp + 8]
mov dword [esp + 0x10], 0
cmp edx, dword [esp + 0x20]
jae 0x4d2563
mov eax, dword [ebp + 0xc]
mov ecx, dword [esp + 8]
mov eax, dword [eax + 8]
movzx eax, byte [eax + edx]
mov byte [esp + 0xc], al
movzx eax, al
movzx edx, byte [ecx + eax + 0x158]
mov ecx, edi
and ecx, 0x7ffffff
add ecx, edx
mov edx, dword [ebx + 0x7c]
cmp ecx, edx
jae 0x4d2857
mov edx, dword [ebx + 0x78]
mov ebx, dword [edx + ecx*4]
test ebx, ebx
js 0x4d26d0
test ebx, 0x8000000
jne 0x4d278d
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
test ebx, 0x20000000
je 0x4d281d
movzx eax, byte [0x5a11e8]
mov eax, dword [0x5a1188]
test eax, eax
jne 0x4d24f6
call dword [sym.imp.kernel32.dll_GetProcessHeap]
test eax, eax
je 0x4d2770
mov dword [0x5a1188], eax
push 0xc
push 0
push eax
call dword [sym.imp.kernel32.dll_HeapAlloc]
test eax, eax
je 0x4d2770
movzx ecx, byte [esp + 0xc]
mov byte [eax], 0
mov byte [eax + 1], cl
mov ecx, dword [esp]
jmp 0x4d2719
mov dword [esp + 0xc], edx
mov edx, dword [ebx + 0x278]
mov edi, dword [esp]
cmp dword [edx + 0x154], edi
jbe 0x4d25d9
lea edx, [edi + edi*2]
mov edi, dword [ebp + 8]
lea ecx, [ecx + edx*2 + 0xc]
mov edx, dword [edi + 0x88]
cmp ecx, edx
jb 0x4d224a
push 0x54ccf4
call fcn.00532ca0
mov esi, edx
cmp edx, dword [esp + 0x20]
jb 0x4d2473
mov eax, dword [esp + 8]
mov ecx, edi
and ecx, 0x7ffffff
movzx eax, byte [eax + 0x257]
shl eax, 0x10
add eax, 0x10001
mov edx, eax
shr edx, 0x10
add ecx, edx
mov edx, dword [ebx + 0x7c]
cmp ecx, edx
jae 0x4d288d
mov edx, dword [ebx + 0x78]
mov ebx, dword [edx + ecx*4]
test ebx, ebx
js 0x4d272c
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
test ebx, 0x8000000
je 0x4d281d
mov ecx, dword [esp + 8]
xor edi, edi
mov edx, 1
mov eax, dword [ecx + 0x278]
cmp dword [eax + 0x154], 1
jne 0x4d262c
mov eax, dword [esp + 0x20]
mov dword [esp + 4], eax
jmp 0x4d281d
mov ecx, dword [ebx + 0x27c]
mov edi, dword [ebp + 8]
mov edx, 1
and ecx, 0x1f
shl edx, cl
cmp ecx, 0x1b
jae 0x4d28fb
or edx, 0x40000000
test edx, edx
jns 0x4d225b
movzx eax, al
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], edi
lea ecx, [esp + 0x28]
lea edx, [esp + 0x30]
push eax
push dword [esp + 4]
push dword [esp + 0x14]
call fcn.00536390
add esp, 0xc
jmp 0x4d2267
mov eax, dword [ebp + 8]
movzx ecx, byte [ecx + 0x27c]
and ebx, 0x7ffffff
mov edx, dword [eax + 0x94]
shr ebx, cl
cmp ebx, edx
jae 0x4d2873
mov eax, dword [eax + 0x90]
mov edx, dword [eax + ebx*8 + 4]
test edx, edx
je 0x4d287f
mov eax, dword [eax + ebx*8]
test byte [eax + 8], 2
jne 0x4d26a8
mov eax, dword [esp + 0x20]
jmp 0x4d27ee
xor eax, eax
cmp dword [esp + 0x10], 0
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
sete al
cmove edx, esi
mov dword [ecx], eax
mov dword [ecx + 4], edx
jmp 0x4d2830
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x14]
mov dword [eax], 0
mov dword [eax + 4], ecx
mov dword [eax + 8], esi
jmp 0x4d2837
mov ecx, dword [esp + 0x20]
cmp edx, 0xd
jb 0x4d2925
add edx, 0xfffffff3
cmp edx, 3
ja 0x4d2811
mov ecx, 4
push 0x54f4ac
call fcn.00532d00
mov ecx, dword [esp + 8]
shl eax, 8
mov edx, edi
mov dword [esp + 0x30], ecx
mov ecx, dword [ebp + 8]
mov dword [esp + 0x34], ecx
lea ecx, [esp + 0x30]
push eax
call fcn.00535080
add esp, 4
test eax, eax
je 0x4d277f
movzx eax, byte [0x5a11e8]
mov ecx, 0xc
mov edx, 4
call fcn.004329c0
mov ecx, dword [esp]
test eax, eax
je 0x4d2770
mov byte [eax], 1
mov dword [eax + 4], ecx
push eax
push 0
push dword [0x5a1188]
mov esi, ecx
jmp 0x4d22a5
mov ecx, dword [esp + 8]
mov edx, edi
mov dword [esp + 0x30], ecx
mov ecx, dword [ebp + 8]
mov dword [esp + 0x34], ecx
lea ecx, [esp + 0x30]
push eax
call fcn.00535080
add esp, 4
test eax, eax
je 0x4d283f
movzx eax, byte [0x5a11e8]
mov ecx, 0xc
mov edx, 4
call fcn.004329c0
mov ecx, dword [esp + 0x20]
test eax, eax
jne 0x4d2716
mov ecx, 4
mov edx, 0xc
call fcn.00531970
mov ebx, edx
test ebx, 0x8000000
je 0x4d24bf
mov ecx, dword [esp + 8]
xor edi, edi
mov edx, 1
mov eax, dword [ecx + 0x278]
cmp dword [eax + 0x154], 1
jne 0x4d27b0
mov eax, dword [esp]
mov dword [esp + 4], eax
jmp 0x4d281d
mov eax, dword [ebp + 8]
movzx ecx, byte [ecx + 0x27c]
and ebx, 0x7ffffff
mov edx, dword [eax + 0x94]
shr ebx, cl
cmp ebx, edx
jae 0x4d2873
mov eax, dword [eax + 0x90]
mov edx, dword [eax + ebx*8 + 4]
test edx, edx
je 0x4d287f
mov eax, dword [eax + ebx*8]
test byte [eax + 8], 2
jne 0x4d27f9
mov eax, dword [esp]
mov dword [esp + 4], eax
mov edx, 1
jmp 0x4d281d
cmp edx, 0xd
jb 0x4d2925
mov ecx, dword [esp]
add edx, 0xfffffff3
cmp edx, 3
jbe 0x4d26c1
mov edi, dword [eax + 0x15]
mov edx, 1
mov dword [esp + 4], ecx
mov ecx, dword [esp + 0x18]
xor eax, eax
test edx, edx
sete al
cmove edi, esi
mov dword [ecx], eax
mov dword [ecx + 4], edi
mov eax, dword [esp + 4]
mov dword [ecx + 8], eax
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov ebx, edx
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
test ebx, 0x8000000
jne 0x4d25b2
jmp 0x4d281d
push 0x54c9c8
call fcn.00532ca0
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 0x20]
push 0x54d310
call fcn.00532ca0
mov ecx, ebx
push 0x54cd04
call fcn.00532ca0
xor ecx, ecx
xor edx, edx
push 0x54f560
call fcn.00532ca0
push 0x54c9d8
call fcn.00532ca0
lea eax, [esp + 0x50]
lea ecx, [esp + 0x30]
mov edx, 0x54d0c4
mov dword [esp + 0x30], 0x54d054
mov dword [esp + 0x34], 1
mov dword [esp + 0x40], 0
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], 1
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], 0x48afa0
call fcn.00532c10
mov ecx, 0xd
mov edx, eax
push 0x54f590
call fcn.00532c40
mov ecx, 4
mov edx, eax
push 0x54f4ac
call fcn.00532d00
mov dword [esp + 0x30], edx
mov dword [esp + 0x34], 0
lea eax, [esp + 0x30]
mov ecx, str.called__Result::unwrap____on_an__Err__value
mov edx, 0x2b
push 0x54cd14
push 0x54badc
push eax
call fcn.00533020
mov ecx, 0xd
push 0x54f590
call fcn.00532c40
int3