Function at 0x4d4cf4
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x414]
sub esp, 0x414
push 0xfffffffffffffffe
push 0x5c0e98
push 0x5181f0
mov eax, dword fs:[0]
push eax
sub esp, 0x54
mov eax, dword [0x5c4e68]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp + 0x410], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov edi, dword [ebp + 0x41c]
mov dword [ebp - 0x54], edi
mov eax, dword [ebp + 0x424]
mov dword [ebp - 0x3c], eax
xor ebx, ebx
mov byte [ebp], bl
mov esi, 0x103
push esi
push ebx
lea eax, [ebp + 1]
push eax
call fcn.005117f0
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x2c], ebx
mov byte [ebp + 0x104], bl
push esi
push ebx
lea eax, [ebp + 0x105]
push eax
call fcn.005117f0
mov dword [ebp - 0x60], ebx
mov dword [ebp - 0x44], ebx
lea ebx, [ebp - 0x2c]
lea esi, [ebp - 0x28]
call fcn.004128bf
call fcn.00412dab
mov dword [ebp - 0x38], eax
call fcn.00412e09
xor ebx, ebx
push ebx
push ebx
call fcn.004127f9
push 1
push 7
call fcn.0041534a
add esp, 0x28
call fcn.0041023c
test eax, eax
jne 0x4d5844
call fcn.00415b70
test eax, eax
je 0x4d4dcd
xor eax, eax
inc eax
jmp 0x4d5846
cmp edi, ebx
jne 0x4d4dfc
push dword [ebp + 0x420]
push str.:5:SaveTillSheets__d__FAILED:_No_PAULA_object_was_provided.
call fcn.004265da
push ebx
push 0xffffffffffffffff
call fcn.0041534a
push dword [ebp - 0x2c]
push dword [ebp - 0x28]
call fcn.004127f9
add esp, 0x18
jmp 0x4d5837
mov esi, dword [ebp + 0x420]
cmp esi, ebx
jge 0x4d4e15
mov ecx, edi
call fcn.0045b8cd
mov dword [ebp + 0x420], eax
mov esi, eax
mov edx, esi
mov ecx, edi
call fcn.0045002c
test eax, eax
jne 0x4d4e2a
push esi
push str.:5:SaveTillSheets__d__FAILED:_The_employee_index_is_not_defined.
jmp 0x4d4ddc
cmp dword [edi + 0x2140], ebx
je 0x4d4e64
mov dword [ebp - 0x48], 1
mov ecx, dword [edi + 0x688]
mov dword [ebp - 0x30], ecx
or eax, 0xffffffff
sub eax, dword [edi + 0x2144]
mov dword [ebp - 0x44], eax
cmp ecx, ebx
jne 0x4d4e84
push dword [edi + esi*4 + 0x198]
push esi
push str.:5:SaveTillSheets__d__FAILED:_No_Cash_Box_has_been_defined_for__s.
jmp 0x4d581c
mov dword [ebp - 0x48], ebx
mov eax, dword [edi + esi*4 + 0x4f4]
mov dword [ebp - 0x30], eax
cmp eax, ebx
je 0x4d580f
cmp dword [eax + 8], ebx
jle 0x4d580f
mov ecx, eax
mov eax, dword [ecx + 8]
mov dword [ebp - 0x5c], eax
mov ecx, edi
call fcn.0045b8cd
mov dword [ebp - 0x58], eax
cmp eax, ebx
jge 0x4d4e9b
mov dword [ebp - 0x58], esi
push ebx
push ebx
call fcn.00489f49
pop ecx
pop ecx
mov edi, eax
call fcn.0042ad00
test eax, eax
jne 0x4d4ec1
push ebx
push ebx
push ebx
call fcn.00489f49
pop ecx
pop ecx
mov ecx, eax
call fcn.0042b0ca
pop ecx
push 0x970
push str..TillSheet.c
xor esi, esi
inc esi
push esi
call fcn.00469252
add esp, 0xc
call fcn.00470f74
mov dword [ebp - 0x64], ebx
mov edx, dword [ebp - 0x3c]
call fcn.004c3b34
test eax, eax
je 0x4d4f1d
cmp dword [ebp - 0x3c], ebx
jne 0x4d4ef3
mov dword [ebp - 0x64], esi
mov eax, dword [ebp + 0x420]
lea ecx, [ebp]
mov ebx, dword [ebp - 0x54]
call fcn.004d699d
cmp dword [ebp - 0x48], 0
je 0x4d4f15
mov eax, dword [ebp - 0x44]
lea ecx, [ebp]
call fcn.004d699d
lea eax, [ebp]
mov dword [ebp - 0x3c], eax
xor ebx, ebx
push dword [ebp - 0x3c]
mov ecx, 0x104
lea eax, [ebp + 0x104]
call fcn.004c3b66
mov esi, eax
call fcn.004c3e68
push ebx
push ebx
call fcn.0048a119
mov edx, eax
mov ecx, esi
call fcn.004c40f5
mov dword [ebp - 0x48], ebx
mov edi, 0x989
push edi
push str..TillSheet.c
mov esi, 0x530484
mov edx, esi
lea ecx, [ebp + 0x104]
call fcn.0042d2c6
add esp, 0x14
jmp 0x4d4f95
cmp dword [ebp - 0x48], 3
jg 0x4d4f9c
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
inc dword [ebp - 0x48]
push edi
push str..TillSheet.c
mov edx, esi
lea ecx, [ebp + 0x104]
call fcn.0042d2c6
pop ecx
pop ecx
cmp eax, ebx
mov dword [ebp - 0x34], eax
je 0x4d4f6c
cmp dword [ebp - 0x34], ebx
jne 0x4d4fff
lea eax, [ebp + 0x104]
push eax
push str.:10:ERROR_7723327:_retried_several_times_and_still_failed_to_open___s__
call fcn.004265da
pop ecx
pop ecx
push 0x536a30
mov eax, dword [ebp - 0x58]
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + eax*4 + 0x198]
call fcn.004c5c61
push eax
push str._s__your_till_cannot_be_saved._nPlease_call__s_to_report_this_problem._nLeave_your_name__your_store_number__and_error_7723327._n_nPress_any_key_to_exit...
push str.___________FAILED___________
push str.NotGood.wav
push ebx
push ebx
push 1
call fcn.00436110
push ebx
push 0xffffffffffffffff
call fcn.0041534a
push dword [ebp - 0x2c]
push dword [ebp - 0x28]
call fcn.004127f9
add esp, 0x30
jmp 0x4d5837
call fcn.0048a51a
test eax, eax
jne 0x4d510c
mov eax, pe_nt_image_headers32
mov esi, dword [ebp - 0x5c]
cmp esi, eax
jg 0x4d501a
mov eax, esi
mov dword [ebp - 0x20], eax
cmp eax, esi
jge 0x4d5065
xor edi, edi
mov dword [ebp - 0x44], edi
lea ecx, [esi - 1]
cmp ecx, ebx
jl 0x4d5052
mov edx, ecx
imul edx, edx, 0x1234
mov edi, dword [ebp - 0x30]
lea edx, [edx + edi + 0x8dc]
mov edi, dword [ebp - 0x44]
cmp dword [edx], ebx
jne 0x4d5052
inc edi
dec ecx
sub edx, 0x1234
cmp ecx, ebx
jge 0x4d5042
cmp edi, eax
jle 0x4d5065
mov dword [ebp - 0x20], edi
mov eax, 0x20a
cmp edi, eax
jle 0x4d5065
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x24], ebx
cmp esi, ebx
jle 0x4d5083
mov eax, dword [ebp - 0x30]
add eax, 0x1040
mov ecx, esi
mov dword [ebp - 0x24], esi
mov dword [eax], ebx
add eax, 0x1234
dec ecx
jne 0x4d5079
push 4
lea eax, [esi + 1]
push eax
call fcn.00511988
pop ecx
pop ecx
mov ecx, eax
mov dword [ebp - 0x1c], ecx
cmp ecx, ebx
je 0x4d50bf
mov dword [ebp - 0x24], ebx
cmp esi, ebx
jle 0x4d50bf
mov eax, dword [ebp - 0x30]
add eax, 0x104c
mov edx, dword [eax]
mov edi, dword [ebp - 0x24]
mov dword [ecx + edi*4], edx
mov dword [eax], ebx
inc dword [ebp - 0x24]
add eax, 0x1234
cmp dword [ebp - 0x24], esi
jl 0x4d50a8
mov dword [ebp - 4], ebx
mov dword [ebp - 0x24], ebx
cmp dword [ebp - 0x24], esi
jge 0x4d5136
mov eax, dword [ebp - 0x24]
imul eax, eax, 0x1234
mov ecx, dword [ebp - 0x30]
lea esi, [eax + ecx]
mov ebx, dword [esi + 0x11b0]
call fcn.004c39fa
mov dword [esi + 0x11b8], eax
mov ecx, dword [esi + 0x11bc]
call fcn.004c3a25
lea eax, [eax*4 + 4]
mov dword [esi + 0x11c0], eax
inc dword [ebp - 0x24]
xor ebx, ebx
mov esi, dword [ebp - 0x5c]
jmp 0x4d50c5
call fcn.0048a51a
dec eax
neg eax
sbb eax, eax
add eax, 0x20
mov esi, dword [ebp - 0x5c]
cmp esi, eax
jle 0x4d5018
call fcn.0048a51a
dec eax
neg eax
sbb eax, eax
add eax, 0x20
jmp 0x4d501a
mov dword [ebp - 4], 0xfffffffe
jmp 0x4d5179
push ebx
push ebx
push dword [ebp - 0x34]
call fcn.005131f0
push dword [ebp - 0x34]
push 1
push 4
lea eax, [ebp - 0x20]
push eax
call fcn.005110f1
mov dword [ebp - 0x48], eax
push dword [ebp - 0x34]
push dword [ebp - 0x20]
mov edi, 0x1234
push edi
mov eax, esi
sub eax, dword [ebp - 0x20]
imul eax, eax, 0x1234
add eax, dword [ebp - 0x30]
push eax
call fcn.005110f1
add esp, 0x2c
mov dword [ebp - 0x44], eax
cmp dword [ebp - 0x1c], ebx
je 0x4d51eb
xor eax, eax
cmp esi, ebx
jle 0x4d51df
mov ecx, dword [ebp - 0x30]
add ecx, 0x104c
mov edx, dword [ebp - 0x1c]
mov edx, dword [edx + eax*4]
mov dword [ecx], edx
inc eax
add ecx, edi
cmp eax, esi
jl 0x4d51d0
push dword [ebp - 0x1c]
call fcn.00511758
pop ecx
mov dword [ebp - 0x1c], ebx
xor eax, eax
inc eax
cmp dword [ebp - 0x48], eax
jne 0x4d579c
mov ecx, dword [ebp - 0x44]
cmp ecx, dword [ebp - 0x20]
jne 0x4d579c
mov dword [ebp - 4], eax
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x50], ebx
mov dword [ebp - 0x4c], ebx
mov edi, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x20]
cmp dword [ebp - 0x4c], ecx
jge 0x4d5251
mov eax, dword [ebp - 0x4c]
sub eax, ecx
add eax, esi
imul eax, eax, 0x1234
add eax, dword [ebp - 0x30]
mov ecx, dword [eax + 0x11b8]
cmp ecx, ebx
jbe 0x4d524c
inc dword [ebp - 0x50]
push edi
push 1
push ecx
push dword [eax + 0x11b0]
call fcn.005110f1
add esp, 0x10
add dword [ebp - 0x40], eax
inc dword [ebp - 0x4c]
jmp 0x4d5212
mov eax, dword [ebp - 0x50]
cmp dword [ebp - 0x40], eax
jge 0x4d52e7
push eax
push dword [ebp - 0x40]
push str.:7:SaveTillSheets___FAILED:_FAILED_to_save_the_Paid_Out_descriptions:_wrote__d_of__d
call fcn.004265da
add esp, 0xc
cmp edi, ebx
je 0x4d527c
mov ecx, edi
call fcn.0042d70e
mov dword [ebp - 0x34], ebx
mov ecx, dword [ebp - 0x58]
mov eax, dword [ebp - 0x54]
mov edx, dword [eax + ecx*4 + 0x198]
call fcn.004c5c61
push eax
push str._s__your_till_cannot_be_saved._nA_file_access_error_has_occurred._n_nPress_any_key_to_exit...
push str.___________FAILED___________
push str.NotGood.wav
push ebx
push ebx
push 1
call fcn.00436110
push ebx
push 0xffffffffffffffff
call fcn.0041534a
push dword [ebp - 0x2c]
push dword [ebp - 0x28]
call fcn.004127f9
add esp, 0x2c
cmp dword [ebp - 0x1c], ebx
je 0x4d52ce
push dword [ebp - 0x1c]
call fcn.00511758
pop ecx
mov dword [ebp - 0x1c], ebx
cmp dword [ebp - 0x38], ebx
je 0x4d52db
push 0x64
pop eax
call fcn.00412f0a
mov dword [ebp - 4], 0xfffffffe
jmp 0x4d5844
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x50], ebx
mov dword [ebp - 0x4c], ebx
mov ecx, dword [ebp - 0x20]
cmp dword [ebp - 0x4c], ecx
jge 0x4d532f
mov eax, dword [ebp - 0x4c]
sub eax, ecx
add eax, esi
imul eax, eax, 0x1234
add eax, dword [ebp - 0x30]
mov ecx, dword [eax + 0x11c0]
cmp ecx, ebx
jbe 0x4d532a
inc dword [ebp - 0x50]
push edi
push 1
push ecx
push dword [eax + 0x11bc]
call fcn.005110f1
add esp, 0x10
add dword [ebp - 0x40], eax
inc dword [ebp - 0x4c]
jmp 0x4d52f0
mov eax, dword [ebp - 0x50]
cmp dword [ebp - 0x40], eax
jge 0x4d5345
push eax
push dword [ebp - 0x40]
push str.:7:SaveTillSheets___FAILED:_FAILED_to_save_the_Applied_Invoice_List:_wrote__d_of__d
jmp 0x4d5266
mov dword [ebp - 4], 0xfffffffe
cmp edi, ebx
je 0x4d5357
mov ecx, edi
call fcn.0042d70e
call fcn.0041023c
test eax, eax
jne 0x4d5844
push 0xa25
mov esi, str..TillSheet.c
push esi
push 1
call fcn.0046c07a
add esp, 0xc
call fcn.0041023c
test eax, eax
je 0x4d538f
push 1
call fcn.0046cf18
pop ecx
jmp 0x4d5844
call fcn.004f16be
mov dword [ebp - 0x44], eax
xor edi, edi
push dword [ebp - 0x3c]
lea eax, [ebp + 0x104]
push eax
call fcn.00403305
pop ecx
pop ecx
test eax, eax
jg 0x4d53eb
call fcn.004f16be
sub eax, dword [ebp - 0x44]
cmp eax, 0x3a98
ja 0x4d53f2
push 1
call fcn.0046cf18
pop ecx
push 0xfa
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0xa38
push esi
push 1
call fcn.0046c07a
add esp, 0xc
mov dword [ebp - 0x60], ebx
inc edi
cmp edi, 7
jl 0x4d5399
jmp 0x4d53f2
mov dword [ebp - 0x60], 1
push 1
call fcn.0046cf18
pop ecx
cmp dword [ebp - 0x60], ebx
jne 0x4d5523
push 0x1388
mov ecx, dword [ebp - 0x3c]
call fcn.0042adc7
pop ecx
push eax
push dword [ebp - 0x3c]
lea eax, [ebp + 0x104]
push eax
mov esi, dword [ebp - 0x54]
call fcn.0045b9cf
push eax
push str.:9:ERROR_7722427:__s_till_sheet___s__could_not_be_archived:___s__DoesFileExist_____d
call fcn.004265da
lea eax, [esi + 0x1094]
push eax
push dword [ebp - 0x3c]
call fcn.004c48c1
add esp, 0x1c
test eax, eax
je 0x4d54eb
mov byte [ebp + 0x30c], bl
mov edi, 0x103
push edi
push ebx
lea eax, [ebp + 0x30d]
push eax
call fcn.005117f0
mov byte [ebp + 0x208], bl
push edi
push ebx
lea eax, [ebp + 0x209]
push eax
call fcn.005117f0
add esp, 0x18
cmp dword [0x6dd840], ebx
jne 0x4d54eb
push dword [ebp - 0x3c]
inc edi
mov ecx, edi
lea eax, [ebp + 0x208]
call fcn.004c3b66
pop ecx
mov esi, eax
call fcn.004c3e68
mov eax, esi
push eax
push str.ServerSync_
push ebx
push ebx
call fcn.00489f49
pop ecx
pop ecx
push eax
push 0x530490
push edi
lea eax, [ebp + 0x30c]
push eax
call fcn.004c53b7
mov dword [0x6dd840], 1
lea eax, [ebp + 0x30c]
push eax
push dword [ebp + 0x420]
push dword [ebp - 0x54]
call fcn.004d4cf4
add esp, 0x24
mov dword [0x6dd840], ebx
jmp 0x4d5846
push 0x536a30
mov eax, dword [ebp - 0x58]
mov edx, dword [esi + eax*4 + 0x198]
call fcn.004c5c61
push eax
push str._s__your_till_cannot_be_saved._nThe_TAMS_server_cannot_be_accessed._nPlease_call__s_to_report_this_problem._nLeave_your_name__your_store_number__and_error_7722427._n_nPress_any_key_to_exit...
push str.___________FAILED___________
push str.NotGood.wav
push ebx
push ebx
push 1
call fcn.00436110
add esp, 0x20
mov dword [ebp - 0x20], ebx
jmp 0x4d56e9
call fcn.0048a51a
test eax, eax
jne 0x4d56e9
cmp dword [ebp - 0x64], ebx
je 0x4d56e9
mov byte [ebp + 0x208], bl
mov esi, 0x103
push esi
push ebx
lea eax, [ebp + 0x209]
push eax
call fcn.005117f0
mov byte [ebp + 0x30c], bl
push esi
push ebx
lea eax, [ebp + 0x30d]
push eax
call fcn.005117f0
push dword [ebp - 0x3c]
lea edi, [esi + 1]
mov ecx, edi
lea eax, [ebp + 0x208]
call fcn.004c3b66
add esp, 0x1c
mov esi, eax
call fcn.004c3e68
push str._tmpP2_NODEL_tills_
call fcn.0046297d
push eax
push 0x56d368
push edi
lea eax, [ebp + 0x30c]
push eax
call fcn.004c53b7
lea eax, [ebp + 0x30c]
push eax
call fcn.0042adad
add esp, 0x18
test eax, eax
jne 0x4d55c0
push ebx
lea ecx, [ebp + 0x30c]
call fcn.0042b0ca
pop ecx
lea eax, [ebp + 0x208]
push eax
mov eax, edi
lea esi, [ebp + 0x30c]
call fcn.004c3c36
mov eax, esi
push eax
lea eax, [ebp + 0x104]
push eax
call fcn.00403305
add esp, 0xc
test eax, eax
jg 0x4d55f9
mov eax, esi
push eax
push str.:5:SaveTillSheets___EAP:_CreateArchive___FAILED_to_create_the_backup_till:__s
call fcn.00426c01
pop ecx
pop ecx
push str._nBacking_up_invoice_registrar...
call fcn.00414d11
mov dword [esp], 0xa72
push str..TillSheet.c
push 0x10
call fcn.0046c07a
add esp, 0xc
mov esi, str._tmpP2_NODEL_tills_
push esi
call fcn.0046297d
push eax
push 0x56d368
push 0x104
lea eax, [ebp + 0x30c]
push eax
call fcn.004c53b7
push str.s_inv.dat
lea edi, [ebp + 0x208]
call fcn.004682da
lea eax, [ebp + 0x30c]
push eax
mov ecx, edi
call fcn.0042a462
push 0x10
call fcn.0046cf18
push str.DONE_
call fcn.00414d11
push str._nBacking_up_sales_data...
call fcn.00414d11
push 0xa7b
push str..TillSheet.c
push 0x40
call fcn.0046c07a
add esp, 0x34
push esi
call fcn.0046297d
push eax
push 0x56d368
push 0x104
lea eax, [ebp + 0x30c]
push eax
call fcn.004c53b7
push str.s_cur.sls
call fcn.004682da
lea eax, [ebp + 0x30c]
push eax
mov ecx, edi
call fcn.0042a462
push str.s_eod.sls
call fcn.004682da
lea eax, [ebp + 0x30c]
push eax
mov ecx, edi
call fcn.0042a462
push 0x40
call fcn.0046cf18
push str.DONE__n
call fcn.00414d11
add esp, 0x2c
lea eax, [ebp + 0x104]
call fcn.0042a76b
push ebx
push 0xffffffffffffffff
call fcn.0041534a
push dword [ebp - 0x2c]
push dword [ebp - 0x28]
call fcn.004127f9
add esp, 0x10
cmp dword [ebp - 0x38], ebx
je 0x4d5717
push 0x64
pop eax
call fcn.00412f0a
mov eax, dword [ebp - 0x20]
jmp 0x4d5846
push dword [ebp - 0x20]
push dword [ebp - 0x44]
push dword [ebp - 0x48]
push str.:9:SaveTillSheets___FAILED:_ERROR_21545__could_not_save_till__result1___d_of_1__result2___d_of__d
call fcn.004265da
add esp, 0x10
mov ecx, dword [ebp - 0x34]
cmp ecx, ebx
je 0x4d57be
call fcn.0042d70e
mov eax, dword [ebp - 0x54]
mov ecx, dword [ebp - 0x58]
mov edx, dword [eax + ecx*4 + 0x198]
call fcn.004c5c61
push eax
push str._s__your_till_cannot_be_saved._nA_file_access_error_has_occurred._n_nPress_any_key_to_exit...
push str.___________FAILED___________
push str.NotGood.wav
push ebx
push ebx
push 1
call fcn.00436110
push ebx
push 0xffffffffffffffff
call fcn.0041534a
push dword [ebp - 0x2c]
push dword [ebp - 0x28]
call fcn.004127f9
add esp, 0x2c
cmp dword [ebp - 0x1c], ebx
je 0x4d5837
push dword [ebp - 0x1c]
call fcn.00511758
pop ecx
jmp 0x4d5837
push dword [edi + esi*4 + 0x198]
push esi
push str.:5:SaveTillSheets__d__FAILED:_No_till_sheets_have_been_defined_for__s.
call fcn.004265da
push ebx
push 0xffffffffffffffff
call fcn.0041534a
push dword [ebp - 0x2c]
push dword [ebp - 0x28]
call fcn.004127f9
add esp, 0x1c
cmp dword [ebp - 0x38], ebx
je 0x4d5844
push 0x64
pop eax
call fcn.00412f0a
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x410]
xor ecx, ebp
call fcn.0051291c
add ebp, 0x414
leave
ret