Function at 0x10014cd0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x34
mov edi, dword [ebp + 8]
test byte [0x10022114], 8
mov ebx, dword [ebp + 0x10]
mov esi, dword [edi + 0x18]
movzx eax, word [esi + 0xb6e]
mov dword [ebp - 0x1c], eax
mov eax, dword [esi + 0x950]
mov dword [ebp - 0x18], eax
mov eax, dword [esi + 0x938]
mov dword [ebp - 0x20], eax
jne 0x10014de8
test ebx, 0x7ffffffe
jne 0x10014f78
mov eax, ebx
and eax, 1
add eax, 0x79
mov word [ebp - 0x12], ax
mov eax, dword [edi + 0x18]
add eax, 0x20
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov edx, dword [edi + 0x18]
mov eax, 0x80040205
sub esp, 4
cmp dword [edx + 0x4c8], 1
je 0x10014d68
mov dword [ebp - 0x18], eax
add edx, 0x20
mov dword [esp], edx
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov eax, dword [ebp - 0x18]
sub esp, 4
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 0xc
test byte [edx + 0x4c0], 1
je 0x10014d46
test ebx, ebx
js 0x10014f60
mov eax, dword [edi]
mov dword [esp], edi
call dword [eax + 0x28]
sub esp, 4
test eax, eax
js 0x10014f51
mov dword [ebp - 0x10], 1
mov eax, dword [ebp - 0x1c]
mov dword [esp + 0x10], eax
mov eax, dword [edi + 0x150]
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x18]
mov dword [esp + 8], eax
movzx eax, byte [esi + 0xcd0]
mov dword [esp], 1
mov dword [esp + 4], eax
call sym._HidP_InitializeReportForID_20
sub esp, 0x14
cmp eax, 0x110000
je 0x10014e28
test eax, eax
js 0x10014f4a
or dword [edi + 0x14c], 1
mov edx, dword [edi + 0x18]
jmp 0x10014d46
mov dword [esp + 0x18], ebx
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x10], edi
mov dword [esp], 3
mov dword [esp + 0x14], eax
mov eax, str.iface__p__iterations__lu__flags__lx._n
mov dword [esp + 0xc], eax
mov eax, str.hid_joystick_effect_Start
mov dword [esp + 8], eax
mov eax, 0x10022114
mov dword [esp + 4], eax
call sym._wine_dbg_log.constprop.0_4
jmp 0x10014d0b
mov ebx, dword [ebp - 0x1c]
mov dword [esp + 0x1c], ebx
mov eax, dword [edi + 0x150]
mov dword [esp + 0x18], eax
mov eax, dword [ebp - 0x18]
mov dword [esp + 0x14], eax
mov eax, dword [edi + 0xc]
mov dword [esp], 1
mov dword [esp + 0x10], eax
mov eax, 0x22
mov dword [esp + 0xc], eax
xor eax, eax
mov dword [esp + 8], eax
mov eax, 0xf
mov dword [esp + 4], eax
call sym._HidP_SetUsageValue_32
sub esp, 0x20
cmp eax, 0x110000
jne 0x10014dcc
mov dword [esp + 0x1c], ebx
mov eax, dword [edi + 0x150]
mov dword [esp + 0x18], eax
mov eax, dword [ebp - 0x18]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x10]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x12]
mov dword [esp + 0xc], eax
movzx eax, word [esi + 0xcd8]
mov dword [esp], 1
mov dword [esp + 8], eax
mov eax, 0xf
mov dword [esp + 4], eax
call sym._HidP_SetUsages_32
sub esp, 0x20
cmp eax, 0x110000
jne 0x10014dcc
mov dword [esp + 0x1c], ebx
mov ecx, 0x7c
xor esi, esi
mov eax, dword [edi + 0x150]
mov dword [esp + 0xc], ecx
mov dword [esp + 8], esi
mov dword [esp], 1
mov dword [esp + 0x18], eax
mov eax, dword [ebp - 0x18]
mov dword [esp + 0x14], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x10], eax
mov eax, 0xf
mov dword [esp + 4], eax
call sym._HidP_SetUsageValue_32
sub esp, 0x20
cmp eax, 0x110000
jne 0x10014dcc
mov dword [esp + 8], ebx
xor eax, eax
xor edx, edx
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], edx
mov eax, dword [edi + 0x150]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_WriteFile]
sub esp, 0x14
test eax, eax
jne 0x10014f82
mov eax, 0x8007001e
and dword [edi + 0x14c], 0xfffffffe
mov edx, dword [edi + 0x18]
jmp 0x10014d46
mov ecx, dword [edi + 0xc]
mov eax, 0x80040203
test ecx, ecx
je 0x10014d46
jmp 0x10014d8c
mov eax, 0x80070057
jmp 0x10014d5b
xor eax, eax
jmp 0x10014dd4