Function at 0x527d05
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x15c
mov eax, dword [0x5f2e68]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
push 6
mov esi, ecx
pop ecx
xor eax, eax
push 0x103
lea edi, [ebp - 0x3b]
push eax
mov byte [ebp - 0x3c], 0
rep stosd dword es:[edi], eax
mov byte [ebp - 0x148], al
lea eax, [ebp - 0x147]
push eax
mov dword [ebp - 0x150], esi
call fcn.005306b0
add esp, 0xc
xor eax, eax
and dword [ebp - 0x14c], eax
and dword [ebp - 0x15c], eax
push 6
pop ecx
lea edi, [ebp - 0x1f]
mov byte [ebp - 0x20], 0
mov edx, esi
rep stosd dword es:[edi], eax
call fcn.004ccc0d
test eax, eax
je 0x527d77
xor eax, eax
jmp 0x5280e8
test ebx, ebx
je 0x527d70
push esi
mov ecx, 0x104
lea eax, [ebp - 0x148]
call fcn.004ccc3f
pop ecx
mov edx, eax
call fcn.004cd7e8
mov eax, edx
push eax
mov esi, 0x5528c8
call fcn.004ccd4e
neg eax
sbb eax, eax
inc eax
xor edi, edi
cmp eax, edi
pop ecx
mov dword [ebp - 0x158], eax
mov dword [ebp - 0x154], edi
je 0x527df9
push edi
push edi
push edi
push edi
push edi
lea eax, [ebp - 0x3c]
push eax
push 0x19
pop eax
call fcn.0046ab1d
add esp, 0x18
lea edx, [ebp - 0x3c]
call fcn.004ccc0d
test eax, eax
jne 0x527df9
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x148]
push eax
call fcn.004cd9f0
test eax, eax
pop ecx
pop ecx
je 0x527df9
mov dword [ebp - 0x154], 1
push edi
mov esi, ebx
call fcn.0052a4ae
pop ecx
lea edx, [ebx + 0x6c]
call fcn.004ccc0d
test eax, eax
jne 0x527e13
cmp dword [ebx + 0x24], edi
je 0x527e1e
push 0x19
lea ecx, [ebp - 0x20]
call fcn.0046b0c2
pop ecx
cmp dword [ebx + 0x88], edi
je 0x527e2b
cmp dword [ebx + 0x24], edi
je 0x527e3d
call fcn.0046b2ee
mov ecx, eax
call fcn.004707d3
mov dword [ebp - 0x14c], eax
cmp dword [ebx + 0x2f8c], edi
jle 0x527e4a
cmp dword [ebx + 0x24], edi
je 0x527e53
call fcn.0046b1b4
mov esi, eax
jmp 0x527e59
mov esi, dword [ebp - 0x15c]
lea edx, [ebp - 0x20]
call fcn.004ccc0d
test eax, eax
jne 0x527e75
lea eax, [ebp - 0x20]
push eax
push 0x19
pop ecx
lea eax, [ebx + 0x6c]
call fcn.004ccc3f
pop ecx
mov eax, dword [ebp - 0x14c]
cmp eax, edi
je 0x527e85
mov dword [ebx + 0x88], eax
cmp esi, edi
jle 0x527e8f
mov dword [ebx + 0x2f8c], esi
call fcn.00418518
cmp dword [ebx + 0x90], 0
mov dword [ebx + 0x24], edi
mov edi, 0x300c
mov dword [ebx + 0x2f90], eax
mov dword [ebx], edi
jne 0x527eb4
and dword [ebx + 0x8c], 0
mov eax, dword [ebx + 0x8c]
mov esi, 0x1f4
cmp eax, esi
jle 0x527ed8
push esi
push eax
push str.:8:SaveSales___FAILED:_The_max_number_of_employees_has_been_exceeded___ld__ld
call fcn.0042b70b
add esp, 0xc
mov dword [ebx + 0x8c], esi
cmp dword [ebp - 0x158], 0
je 0x527f07
call fcn.00531157
push eax
push 0
push 0
call fcn.00493154
pop ecx
pop ecx
push eax
lea eax, [ebp - 0x148]
push str._stemp_d.sls
push eax
call fcn.00531b2f
add esp, 0x10
xor edx, edx
xor eax, eax
cmp eax, 4
jb 0x527f15
cmp eax, 8
jb 0x527f29
cmp eax, 0x90
jl 0x527f23
cmp eax, 0x94
jl 0x527f29
movzx ecx, byte [ebx + eax]
add edx, ecx
inc eax
cmp eax, edi
jb 0x527f0b
mov eax, dword [ebx + 0x8c]
add edx, edi
test eax, eax
jle 0x527f64
shl eax, 6
xor ecx, ecx
test eax, eax
jle 0x527f62
mov esi, dword [ebx + 0x8c]
mov eax, dword [ebx + 0x90]
shl esi, 6
movzx edi, byte [eax + ecx]
add edx, edi
inc ecx
cmp ecx, esi
jl 0x527f52
mov edi, 0x300c
add edx, ecx
mov dword [ebx + 4], edx
push 0x10c
push str..GetSalesSa7.c
mov edx, 0x54f4b4
lea ecx, [ebp - 0x148]
call fcn.00434df1
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x527d70
push esi
push 1
push edi
push ebx
call fcn.00531aad
add esp, 0x10
cmp eax, 1
je 0x527fd9
mov ecx, esi
call fcn.00435239
cmp dword [ebp - 0x158], 0
je 0x527fba
lea eax, [ebp - 0x148]
call fcn.004314ff
push dword [ebp - 0x150]
lea eax, [ebp - 0x148]
push eax
push str.:6:SaveSales___FAILED_to_fwrite_to___s__for___s_
call fcn.0042b70b
add esp, 0xc
jmp 0x527d70
mov eax, dword [ebx + 0x8c]
xor edi, edi
cmp eax, edi
jle 0x528027
mov dword [ebp - 0x14c], edi
mov eax, dword [ebx + 0x90]
add eax, dword [ebp - 0x14c]
push esi
push 1
push 0x40
push eax
call fcn.00531aad
add esp, 0x10
cmp eax, 1
je 0x528017
push edi
push str.:7:SaveSales___FAILED:_fwrite___FAILED_to_write_cashier_index__d.
call fcn.0042b70b
pop ecx
pop ecx
add dword [ebp - 0x14c], 0x40
inc edi
cmp edi, dword [ebx + 0x8c]
jl 0x527feb
mov ecx, esi
call fcn.00435239
xor edi, edi
cmp dword [ebp - 0x158], edi
je 0x5280e5
cmp dword [ebp - 0x154], edi
je 0x52805d
cmp dword [ebp + 8], edi
je 0x52805d
push 0x132
push str..GetSalesSa7.c
push 0x40
call fcn.00474c00
add esp, 0xc
call fcn.004fa8e4
mov edx, dword [ebp - 0x150]
push edi
lea ecx, [ebp - 0x148]
mov esi, eax
call fcn.004315a3
cmp eax, edi
pop ecx
jne 0x5280c5
call fcn.004fa8e4
sub eax, esi
cmp eax, 0x1388
jae 0x5280ab
push 0xfa
call dword [sym.imp.KERNEL32.dll_Sleep]
mov edx, dword [ebp - 0x150]
push edi
lea ecx, [ebp - 0x148]
call fcn.004315a3
cmp eax, edi
pop ecx
jne 0x5280c5
push dword [ebp - 0x150]
lea eax, [ebp - 0x148]
push eax
push str.:7:SaveSales___FAILED_to_CopyFileSafe___s_____s___0__
call fcn.0042bd38
add esp, 0xc
cmp dword [ebp - 0x154], edi
je 0x5280da
cmp dword [ebp + 8], edi
je 0x5280da
push 0x40
call fcn.00475a9e
pop ecx
lea eax, [ebp - 0x148]
call fcn.004314ff
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.005317e7
leave
ret