Function at 0x49d565
Capabilities:
Decompress data using aplib

Disassembly:
pushal
call 0x49d006
pop ebp
sub ebp, 0x444a0a
mov ebx, 0x444a04
add ebx, ebp
sub ebx, dword [ebp + 0x4450b1]
cmp dword [ebp + 0x4450ac], 0
mov dword [ebp + 0x444ebb], ebx
jne 0x49d544
lea eax, [ebp + 0x4450d1]
push eax
call dword [ebp + 0x445194]
mov dword [ebp + 0x4450cd], eax
mov edi, eax
lea ebx, [ebp + 0x4450de]
push ebx
push eax
call dword [ebp + 0x445190]
mov dword [ebp + 0x4450b9], eax
lea ebx, [ebp + 0x4450eb]
push ebx
push edi
call dword [ebp + 0x445190]
mov dword [ebp + 0x4450bd], eax
mov eax, dword [ebp + 0x444ebb]
mov dword [ebp + 0x4450ac], eax
push 4
push 0x1000
push 0x49a
push 0
call dword [ebp + 0x4450b9]
mov dword [ebp + 0x4450b5], eax
lea ebx, [ebp + 0x444acf]
push eax
push ebx
call 0x49d565
mov ecx, eax
lea edi, [ebp + 0x444acf]
mov esi, dword [ebp + 0x4450b5]
sar ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebp + 0x4450b5]
push 0x8000
push 0
push eax
call dword [ebp + 0x4450bd]
lea ecx, [esi]
test dword [edi], esi
dec esp
inc esp
pop es
push eax
ret
mov eax, 0x3f419b9c
mov word [ebx], ds
xchg edx, eax
add dword [ebp - 0x57b3bf3a], ebx
dec eax
jnp 0x49d55d
invalid
lodsb al, byte [esi]
push edi
dec eax
mov edi, 0x59309bd3
push ebp
mov ebp, esp
pushal
push ebp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add dl, dl
jne 0x49d582
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x49d573
add dl, dl
jne 0x49d58d
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x49d5d9
xor eax, eax
add dl, dl
jne 0x49d59a
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x49d676
add dl, dl
jne 0x49d5a9
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x49d5b4
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x49d5bf
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x49d5ca
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
je 0x49d5d4
push edi
sub edi, eax
mov al, byte [edi]
pop edi
mov byte [edi], al
inc edi
jmp 0x49d579
mov eax, 1
add dl, dl
jne 0x49d5e7
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x49d5f2
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x49d5de
sub eax, 2
jne 0x49d621
mov ecx, 1
add dl, dl
jne 0x49d607
mov dl, byte [esi]
inc esi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x49d612
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x49d5fe
push esi
mov esi, edi
sub esi, ebp
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x49d579
dec eax
shl eax, 8
mov al, byte [esi]
inc esi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x49d638
mov dl, byte [esi]
inc esi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x49d643
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x49d62f
cmp eax, 0x7d00
jae 0x49d666
cmp eax, 0x500
jb 0x49d661
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x49d579
cmp eax, 0x7f
ja 0x49d669
add ecx, 2
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x49d579
mov al, byte [esi]
inc esi
xor ecx, ecx
shr al, 1
je 0x49d692
adc ecx, 2
mov ebp, eax
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x49d579
pop ebp
sub edi, dword [ebp + 0xc]
mov dword [ebp - 4], edi
popal
pop ebp
ret 8