Function at 0x4996a2
Capabilities:
Decompress data using quicklz

Disassembly:
push ecx
push ebx
push ebp
push esi
mov esi, dword [esp + 0x18]
mov ebp, edx
push edi
mov edi, ecx
test ebp, ebp
je 0x49994f
mov ebx, dword [ebp]
mov ecx, ebx
and ebx, 0xffffff
shr ecx, 0x18
cmp edi, ebx
jae 0x49994f
cmp cl, 1
jne 0x4996d9
movzx edx, byte [edi + ebp + 8]
jmp 0x499711
cmp cl, 2
jne 0x4996e5
movzx edx, word [ebp + edi*2 + 8]
jmp 0x499711
cmp cl, 3
jne 0x499704
lea eax, [edi*2]
add eax, ebp
movzx edx, byte [edi + eax + 0xa]
movzx eax, word [edi + eax + 8]
shl edx, 8
or edx, eax
jmp 0x499711
cmp cl, 4
jne 0x49994f
mov edx, dword [ebp + edi*4 + 8]
mov edi, ecx
imul edi, ebx
add edi, 8
add edi, ebp
mov ecx, dword [edi + edx]
lea ebx, [edi + edx]
mov dword [esp + 0x10], ecx
test cl, 1
je 0x4997e6
shr ecx, 2
add edx, 5
xor cl, byte [esi]
and cl, 1
xor byte [esi], cl
mov eax, dword [ebx]
shr eax, 4
and eax, 0x1ff
mov dword [esi + 1], eax
movzx ecx, byte [ebx + 3]
movzx eax, byte [ebx + 4]
shl ecx, 8
or ecx, eax
mov dword [esi + 5], ecx
mov eax, dword [ebx]
shr eax, 0xd
and eax, 0x7ff
add eax, dword [ebp + 4]
mov dword [esi + 9], eax
test byte [ebx], 8
je 0x4997b3
mov ecx, dword [edi + edx]
add edx, 4
test ecx, ecx
jns 0x4997ae
lea eax, [ecx*8]
sar eax, 3
mov dword [esi + 0x19], eax
test ecx, 0x20000000
je 0x499796
lea eax, [edi + edx]
add edx, 4
mov eax, dword [eax]
jmp 0x499798
xor eax, eax
mov dword [esi + 0x15], eax
test ecx, 0x40000000
je 0x4997c8
mov eax, dword [edi + edx]
add edx, 4
mov dword [esi + 0xd], eax
jmp 0x4997c8
mov dword [esi + 0xd], ecx
jmp 0x4997ba
mov dword [esi + 0xd], 0xffffffff
mov dword [esi + 0x15], 0
mov dword [esi + 0x19], 0xffffffff
test byte [ebx], 2
mov eax, dword [esp + 0x18]
jne 0x4998a6
mov eax, dword [edi + edx]
mov ecx, 0x11
pop edi
mov dword [ecx + esi], eax
pop esi
pop ebp
pop ebx
pop ecx
ret
shr dword [esp + 0x10], 3
mov al, byte [esi]
xor byte [esp + 0x10], al
and byte [esp + 0x10], 1
xor byte [esp + 0x10], al
mov eax, dword [esp + 0x10]
mov byte [esi], al
mov eax, dword [ebx]
test ecx, 2
jne 0x4998b4
shr eax, 4
add edx, 7
and eax, 0xfff
mov dword [esi + 1], eax
movzx ecx, word [ebx + 4]
movzx eax, byte [ebx + 6]
and ecx, 0xfffffffe
shl ecx, 7
or ecx, eax
mov dword [esi + 5], ecx
movzx eax, word [ebx + 2]
add eax, dword [ebp + 4]
mov dword [esi + 9], eax
test byte [ebx + 4], 1
je 0x499885
mov ecx, dword [edi + edx]
add edx, 4
test ecx, ecx
jns 0x499880
lea eax, [ecx*8]
sar eax, 3
mov dword [esi + 0x19], eax
test ecx, 0x20000000
je 0x499868
lea eax, [edi + edx]
add edx, 4
mov eax, dword [eax]
jmp 0x49986a
xor eax, eax
mov dword [esi + 0x15], eax
test ecx, 0x40000000
je 0x49989a
mov eax, dword [edi + edx]
add edx, 4
mov dword [esi + 0xd], eax
jmp 0x49989a
mov dword [esi + 0xd], ecx
jmp 0x49988c
mov dword [esi + 0xd], 0xffffffff
mov dword [esi + 0x15], 0
mov dword [esi + 0x19], 0xffffffff
test byte [ebx], 4
mov eax, dword [esp + 0x18]
jne 0x4998a6
mov eax, dword [edi + edx]
mov ecx, 0x11
pop edi
mov dword [ecx + esi], eax
pop esi
pop ebp
pop ebx
pop ecx
ret
shr eax, 5
add edx, 0xc
mov dword [esi + 1], eax
mov eax, dword [ebx + 4]
mov dword [esi + 5], eax
mov eax, dword [ebx + 8]
add eax, dword [ebp + 4]
mov dword [esi + 9], eax
test byte [ebx], 0x10
je 0x499917
mov ecx, dword [edi + edx]
add edx, 4
test ecx, ecx
jns 0x499912
lea eax, [ecx*8]
sar eax, 3
mov dword [esi + 0x19], eax
test ecx, 0x20000000
je 0x4998fa
lea eax, [edi + edx]
add edx, 4
mov eax, dword [eax]
jmp 0x4998fc
xor eax, eax
mov dword [esi + 0x15], eax
test ecx, 0x40000000
je 0x49992c
mov eax, dword [edi + edx]
add edx, 4
mov dword [esi + 0xd], eax
jmp 0x49992c
mov dword [esi + 0xd], ecx
jmp 0x49991e
mov dword [esi + 0xd], 0xffffffff
mov dword [esi + 0x15], 0
mov dword [esi + 0x19], 0xffffffff
test byte [ebx], 4
mov ecx, 0x11
je 0x499943
mov eax, dword [esp + 0x18]
pop edi
mov dword [ecx + esi], eax
pop esi
pop ebp
pop ebx
pop ecx
ret
mov eax, dword [edi + edx]
pop edi
mov dword [ecx + esi], eax
pop esi
pop ebp
pop ebx
pop ecx
ret
and byte [esi], 0xfe
mov eax, 0x11
pop edi
mov dword [esi + 1], 0
mov dword [esi + 5], 0
mov dword [esi + 9], 0
mov dword [esi + 0xd], 0
mov dword [esi + 0x15], 0
mov dword [esi + 0x19], 0xffffffff
mov dword [eax + esi], 0x80004005
pop esi
pop ebp
pop ebx
pop ecx
ret