Function at 0x512b00
Capabilities:
Set console window title

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x640398
push 0x5b6db0
mov eax, dword fs:[0]
push eax
sub esp, 8
mov eax, 0x328c
call fcn.005b5910
mov eax, dword [0x6fb448]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x24], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov dword [ebp - 0x3080], 0
mov dword [ebp - 0x3084], 0
mov dword [ebp - 0x30a0], 0
mov dword [ebp - 0x3038], 0
push 0x3008
push 0
lea eax, [ebp - 0x3034]
push eax
call fcn.005b02a0
add esp, 0xc
mov dword [ebp - 0x30a8], 0
mov dword [ebp - 0x307c], 0
mov dword [ebp - 0x30ac], 0
mov dword [ebp - 0x3098], 0
mov dword [ebp - 0x3094], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x3090], 0
mov dword [ebp - 0x309c], 0
mov byte [ebp - 0x3078], 0
push 0x3f
push 0
lea ecx, [ebp - 0x3077]
push ecx
call fcn.005b02a0
add esp, 0xc
mov dword [ebp - 0x308c], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x3088], 0
mov dword [ebp - 0x30a4], 0
call fcn.004019e7
push 1
call fcn.0051d0c0
call fcn.00402dd3
push eax
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x512c56
xor edx, edx
je 0x512c56
push 0
call fcn.00402af9
add esp, 4
push eax
push str.MISSION_CONTROL
call fcn.0040211c
push eax
push str.__PAULA_Aggregate_Server_v_s:___s___s__
push 0
call fcn.0040114f
add esp, 0x14
push eax
call dword [sym.imp.KERNEL32.dll_SetConsoleTitleA]
call fcn.0040271b
mov dword [ebp - 0x3080], eax
cmp dword [ebp - 0x3080], 0
jne 0x512c7c
push str.:10:FATAL_SERVER_ERROR:_The_PAULA_object_could_not_be_created_
call fcn.00401014
add esp, 4
jmp 0x5141d6
push 0x300c
push 0
lea eax, [ebp - 0x3038]
push eax
call fcn.005b02a0
add esp, 0xc
mov dword [ebp - 0x3014], 1
call fcn.00401190
mov dword [ebp - 0x3090], eax
wait
mov dword [ebp - 4], 0
call fcn.00401636
call fcn.00401893
wait
mov dword [ebp - 4], 0xfffffffe
jmp 0x512ce0
call fcn.0040323d
mov dword [ebp - 0x309c], eax
push str._nLoading_configuration.
push 7
call fcn.00401c2b
add esp, 8
push 0x6bb850
mov ecx, dword [ebp - 0x3080]
push ecx
call fcn.0040176c
add esp, 8
mov dword [ebp - 0x307c], eax
cmp dword [ebp - 0x307c], 0
je 0x512da6
mov edx, dword [ebp - 0x307c]
push edx
push 0x6bb858
push str.PaulaServer___could_not_LoadConfigSettings__s__because___s__Trying_again...
call fcn.004018ca
add esp, 0xc
push 0x6bb8ac
mov eax, dword [ebp - 0x3080]
push eax
call fcn.0040176c
add esp, 8
mov dword [ebp - 0x307c], eax
cmp dword [ebp - 0x307c], 0
je 0x512da6
mov dword [ebp - 0x30b0], 0
mov dword [ebp - 0x30b0], 0
jmp 0x512d82
mov ecx, dword [ebp - 0x30b0]
add ecx, 1
mov dword [ebp - 0x30b0], ecx
cmp dword [ebp - 0x30b0], 0xf
jge 0x512da6
mov edx, dword [ebp - 0x307c]
push edx
push 0x6bb8b4
push str.PaulaServer___FAILED_to_LoadConfigSettings__s__because___s__Continuing_anyway...
call fcn.00401014
add esp, 0xc
jmp 0x512d73
push str._nInitializing..
push 7
call fcn.00401c2b
add esp, 8
push 0x139
push 0x6bb924
push 0
call fcn.00402036
add esp, 0xc
xor eax, eax
je 0x512e27
push 0x13d
push 0x6bb934
push 0x6bb944
push 0
push 0
push 0x826480
push 0x514200
push 0
push 0
call fcn.00401e92
mov dword [ebp - 0x30a8], eax
cmp dword [ebp - 0x30a8], 0
je 0x512e27
push 0x13e
push 0x6bb950
push 0x6bb960
mov ecx, dword [ebp - 0x30a8]
push ecx
call fcn.00401f5a
mov dword [ebp - 0x30a8], 0
mov dword [0x826480], 0
push 0x143
push 0x6bb96c
push 0x6bb97c
push 0
push 0
push 0x826480
push 0x51c3c0
push 0
push 0
call fcn.00401e92
mov dword [ebp - 0x30a8], eax
cmp dword [ebp - 0x30a8], 0
jne 0x512e7a
push 0x6bb988
push str.:9:PaulaServer___FAILED:_Could_not_start_the_termination_detection_thread___s
call fcn.00401014
add esp, 8
jmp 0x512e9f
push 0x149
push 0x6bb9e8
push 0x6bb9f8
mov edx, dword [ebp - 0x30a8]
push edx
call fcn.00401f5a
mov dword [ebp - 0x30a8], 0
wait
mov dword [ebp - 4], 1
push 0
call fcn.0051d0c0
push 0
call fcn.00401f82
add esp, 4
mov eax, dword [ebp - 0x3080]
push eax
call fcn.00514490
add esp, 4
push str._nSetting_file_access_rights...
push 7
call fcn.00401c2b
add esp, 8
push 1
push 0
call fcn.00402982
add esp, 8
mov ecx, dword [ebp - 0x3080]
cmp dword [ecx + 0xd90], 0x1dcd79e3
jne 0x512f19
push str.10.164.136.136
push 0
push 0
call fcn.00402d24
add esp, 8
push eax
call fcn.005b0770
add esp, 8
test eax, eax
je 0x512f19
call fcn.00401bf9
jmp 0x512f1e
call fcn.0040124e
push str._nLogging_resources...
push 7
call fcn.00401c2b
add esp, 8
xor edx, edx
je 0x512f5f
mov byte [ebp - 0x30f0], 0
push 0x3f
push 0
lea eax, [ebp - 0x30ef]
push eax
call fcn.005b02a0
add esp, 0xc
lea ecx, [ebp - 0x30f0]
push ecx
push str.:8:A_critical_file_is_missing:__s
call fcn.00401014
add esp, 8
push str._nLogging_on_to_server...
push 7
call fcn.00401c2b
add esp, 8
push 0x19e
push 0x6bba8c
push 0
call fcn.0040312f
add esp, 0xc
push 0x3f
lea edx, [ebp - 0x3078]
push edx
call fcn.00402626
add esp, 8
push 0x6bba9c
push 0
call fcn.00401474
add esp, 8
push eax
call fcn.004028ab
add esp, 4
test eax, eax
je 0x513160
mov word [ebp - 0x3100], 0
xor eax, eax
mov dword [ebp - 0x30fe], eax
mov dword [ebp - 0x30fa], eax
mov dword [ebp - 0x30f6], eax
mov word [ebp - 0x30f2], ax
mov word [ebp - 0x3110], 0
xor ecx, ecx
mov dword [ebp - 0x310e], ecx
mov dword [ebp - 0x310a], ecx
mov dword [ebp - 0x3106], ecx
mov word [ebp - 0x3102], cx
push 0x1a7
push 0x6bbaac
lea edx, [ebp - 0x3110]
push edx
call fcn.00402036
add esp, 0xc
push 0
push 0
lea eax, [ebp - 0x3100]
push eax
push 0
push 0
push 0x6bbabc
push 0
call fcn.00401474
add esp, 8
push eax
call fcn.00402f86
add esp, 8
mov ecx, esp
mov edx, dword [ebp - 0x3100]
mov dword [ecx], edx
mov eax, dword [ebp - 0x30fc]
mov dword [ecx + 4], eax
mov edx, dword [ebp - 0x30f8]
mov dword [ecx + 8], edx
mov eax, dword [ebp - 0x30f4]
mov dword [ecx + 0xc], eax
sub esp, 0x10
mov ecx, esp
mov edx, dword [ebp - 0x3110]
mov dword [ecx], edx
mov eax, dword [ebp - 0x310c]
mov dword [ecx + 4], eax
mov edx, dword [ebp - 0x3108]
mov dword [ecx + 8], edx
mov eax, dword [ebp - 0x3104]
mov dword [ecx + 0xc], eax
call fcn.00401a00
add esp, 0x20
push eax
call fcn.005bad40
add esp, 4
cmp eax, 0x5265c00
jle 0x513160
push 0x1388
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0
push 0
lea ecx, [ebp - 0x3100]
push ecx
push 0
push 0
push 0x6bbacc
push 0
call fcn.00401474
add esp, 8
push eax
call fcn.00402f86
add esp, 8
mov edx, esp
mov eax, dword [ebp - 0x3100]
mov dword [edx], eax
mov ecx, dword [ebp - 0x30fc]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0x30f8]
mov dword [edx + 8], eax
mov ecx, dword [ebp - 0x30f4]
mov dword [edx + 0xc], ecx
sub esp, 0x10
mov edx, esp
mov eax, dword [ebp - 0x3110]
mov dword [edx], eax
mov ecx, dword [ebp - 0x310c]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0x3108]
mov dword [edx + 8], eax
mov ecx, dword [ebp - 0x3104]
mov dword [edx + 0xc], ecx
call fcn.00401a00
add esp, 0x20
push eax
call fcn.005bad40
add esp, 4
cmp eax, 0x5265c00
jle 0x513160
push str.TenderTypes.htm
push 0
call fcn.00401474
add esp, 8
push eax
call fcn.0040255e
add esp, 4
push str.:2:The_tender_type_HTML_help_file_was_deleted.
call fcn.004018ca
add esp, 4
xor edx, edx
je 0x513169
call fcn.00401276
mov dword [ebp - 0x308c], 0
mov eax, dword [ebp - 0x3080]
add eax, 0x1094
push eax
call fcn.00401956
add esp, 4
wait
mov dword [ebp - 4], 0xfffffffe
jmp 0x5131ae
mov dword [ebp - 0x3084], 0
xor ecx, ecx
je 0x513227
push 1
push 0
push 0
push 1
call fcn.00401b40
add esp, 0x10
test eax, eax
jne 0x513227
push str._nDownloading_MySQL_plugin...
call fcn.00401c2b
add esp, 4
push str.:2:FYI:_PaulaServer___is_downloading_the_MySQL_database_plugin.
call fcn.004018ca
add esp, 4
push 1
push 0
push 1
push 0
call fcn.00401b40
add esp, 0x10
test eax, eax
je 0x51320d
push 0x6bbba8
call fcn.00401c2b
add esp, 4
jmp 0x51321a
push 0x6bbbac
call fcn.00401c2b
add esp, 4
push 0x6bbbb8
call fcn.00401c2b
add esp, 4
call fcn.00401f14
call fcn.00401a96
push 0
call fcn.004019b0
add esp, 4
mov dword [ebp - 0x3088], eax
push str._nSESSION_READY_TO_START_n
push 7
call fcn.00401c2b
add esp, 8
wait
mov dword [ebp - 4], 2
mov dword [ebp - 0x30ac], 0
jmp 0x513273
mov edx, dword [ebp - 0x30ac]
add edx, 1
mov dword [ebp - 0x30ac], edx
cmp dword [0x826480], 0
jne 0x514012
mov dword [ebp - 0x1c], 0x1ea
mov dword [0x820440], 0
push 0
lea eax, [ebp - 0x3290]
push eax
call fcn.00402dec
add esp, 0xfffffff4
mov ecx, esp
mov edx, dword [eax]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov edx, dword [eax + 8]
mov dword [ecx + 8], edx
mov eax, dword [eax + 0xc]
mov dword [ecx + 0xc], eax
call fcn.004010a5
add esp, 0x14
push eax
mov ecx, dword [ebp - 0x30ac]
push ecx
push str._nStarting_loop__d:__s
push 7
call fcn.00401c2b
add esp, 0x10
push 0x1ed
call fcn.00403166
add esp, 4
push 1
push 0
call fcn.0051acf0
add esp, 8
test eax, eax
je 0x5133fc
push 0x1f4
push 0x6bbbf0
push 0x80
call fcn.0040312f
add esp, 0xc
test eax, eax
jle 0x5133c1
call fcn.0040323d
sub eax, dword [0x826484]
cmp eax, 0x36ee80
jbe 0x513344
call fcn.0040323d
mov dword [0x826484], eax
push str.:5:System_has_been_locked_in_standby_for_over_an_hour.
call fcn.00401014
add esp, 4
jmp 0x5133bf
mov word [ebp - 0x3120], 0
xor edx, edx
mov dword [ebp - 0x311e], edx
mov dword [ebp - 0x311a], edx
mov dword [ebp - 0x3116], edx
mov word [ebp - 0x3112], dx
lea eax, [ebp - 0x3120]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx ecx, word [ebp - 0x311a]
cmp ecx, dword [0x82648c]
je 0x51339e
push str.:0:TAMS_is_restarting.__Entering_standby...
call fcn.004018ca
add esp, 4
movzx edx, word [ebp - 0x311a]
mov dword [0x82648c], edx
push 0x826480
push 0x493e0
call fcn.00403071
add esp, 8
call fcn.0040323d
mov dword [0x826488], eax
jmp 0x513264
jmp 0x5133fc
call fcn.0040323d
mov dword [0x826484], eax
call fcn.0040323d
sub eax, dword [0x826488]
cmp eax, 0x1d4c0
jae 0x5133fc
push 0x826480
push 0xea60
call fcn.00403071
add esp, 8
push str.:0:Exiting_standby_after_TAMS_reboot...
call fcn.004018ca
add esp, 4
mov eax, 0x216
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x216
call fcn.00403166
add esp, 4
push 0x826480
call fcn.00401140
add esp, 4
test eax, eax
je 0x51343d
call fcn.0040323d
sub eax, dword [ebp - 0x3084]
cmp eax, 0x1b7740
jbe 0x51359e
cmp dword [ebp - 0x3084], 0
jne 0x513462
push 0x826480
call fcn.00401140
add esp, 4
test eax, eax
je 0x513462
call fcn.0040323d
mov dword [ebp - 0x3084], eax
call fcn.0040323d
mov esi, eax
sub esi, dword [ebp - 0x3084]
call fcn.004015eb
mov edi, eax
sub edi, 1
neg edi
sbb edi, edi
and edi, 0xfffb6c20
add edi, 0x927c0
call fcn.005b3db0
cdq
mov ecx, 0xea60
idiv ecx
sub edi, edx
cmp esi, edi
jbe 0x51359e
push str._nSyncronizing_all_files...
push 7
call fcn.00401c2b
add esp, 8
push 0x229
push 0x6bbca8
push 0xf97f
call fcn.0040312f
add esp, 0xc
test eax, eax
jne 0x513535
push 0x6bbcbc
push 7
call fcn.00401c2b
add esp, 8
cmp dword [0x6bbcb8], 0
je 0x51351a
mov byte [ebp - 0x3228], 0
push 0x103
push 0
lea edx, [ebp - 0x3227]
push edx
call fcn.005b02a0
add esp, 0xc
push 0
lea eax, [ebp - 0x3228]
push eax
call fcn.0040311b
add esp, 8
mov dword [0x6bbcb8], 0
push 1
call fcn.0051bf70
add esp, 4
call fcn.004023ab
mov dword [ebp - 0x3098], 0
jmp 0x51358e
push str.FAILED.
push 7
call fcn.00401c2b
add esp, 8
push 0
call fcn.0051bf70
add esp, 4
mov ecx, dword [ebp - 0x3098]
add ecx, 1
mov dword [ebp - 0x3098], ecx
cmp dword [ebp - 0x3098], 0xf
jle 0x51357a
push 0x6bbcc8
mov edx, dword [ebp - 0x3080]
push edx
call fcn.0040176c
add esp, 8
mov eax, dword [ebp - 0x3080]
add eax, 0x1094
push eax
call fcn.00401956
add esp, 4
call fcn.00402d83
call fcn.0040323d
mov dword [ebp - 0x3084], eax
mov ecx, 0x24c
sub ecx, dword [ebp - 0x1c]
mov dword [0x820440], ecx
push 0x24c
call fcn.00403166
add esp, 4
push 0
push 0x124f80
call fcn.00401d75
add esp, 8
mov edx, 0x255
sub edx, dword [ebp - 0x1c]
mov dword [0x820440], edx
push 0x255
call fcn.00403166
add esp, 4
call fcn.004014b5
mov eax, 0x259
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x259
call fcn.00403166
add esp, 4
mov ecx, dword [ebp - 0x3080]
push ecx
call fcn.005157a0
add esp, 4
mov edx, 0x25d
sub edx, dword [ebp - 0x1c]
mov dword [0x820440], edx
push 0x25d
call fcn.00403166
add esp, 4
call fcn.00514750
mov eax, 0x262
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x262
call fcn.00403166
add esp, 4
call fcn.0040323d
sub eax, dword [ebp - 0x3094]
cmp eax, 0x927c0
jbe 0x513668
call fcn.0040323d
mov dword [ebp - 0x3094], eax
call fcn.0040323d
sub eax, dword [ebp - 0x309c]
cmp eax, 0x124f80
jbe 0x51368f
call fcn.00401636
call fcn.0040219e
call fcn.0040323d
mov dword [ebp - 0x309c], eax
mov ecx, 0x275
sub ecx, dword [ebp - 0x1c]
mov dword [0x820440], ecx
push 0x275
call fcn.00403166
add esp, 4
cmp dword [0x826480], 0
jne 0x513773
cmp dword [ebp - 0x30ac], 0
je 0x5136e6
push 0
push 0x20
call fcn.0040205e
add esp, 8
test eax, eax
je 0x5136e6
call fcn.0040323d
sub eax, dword [ebp - 0x30a4]
cmp eax, 0x1b7740
jbe 0x513773
mov edx, 0x27c
sub edx, dword [ebp - 0x1c]
mov dword [0x820440], edx
push 0x27c
call fcn.00403166
add esp, 4
push 1
call fcn.00401037
add esp, 4
mov eax, 0x282
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x282
call fcn.00403166
add esp, 4
xor ecx, ecx
je 0x513734
call fcn.0040323d
mov dword [ebp - 0x30a4], eax
mov edx, 0x287
sub edx, dword [ebp - 0x1c]
mov dword [0x820440], edx
push 0x287
call fcn.00403166
add esp, 4
push 0
call fcn.00401f82
add esp, 4
mov eax, 0x28b
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x28b
call fcn.00403166
add esp, 4
cmp dword [0x826480], 0
je 0x513781
jmp 0x513264
mov ecx, 0x292
sub ecx, dword [ebp - 0x1c]
mov dword [0x820440], ecx
push 0x292
call fcn.00403166
add esp, 4
wait
mov dword [ebp - 4], 3
mov edx, dword [ebp - 0x3080]
push edx
call fcn.0051aa00
add esp, 4
wait
mov dword [ebp - 4], 2
jmp 0x5137da
push 1
push 0
call fcn.0051acf0
add esp, 8
test eax, eax
je 0x513808
mov eax, 1
test eax, eax
je 0x5137fc
mov dword [ebp - 0x20], 0x1b7740
jmp 0x513803
mov dword [ebp - 0x20], 0x927c0
jmp 0x5139ad
mov ecx, 1
test ecx, ecx
je 0x5139a6
mov word [ebp - 0x3238], 0
xor edx, edx
mov dword [ebp - 0x3236], edx
mov dword [ebp - 0x3232], edx
mov dword [ebp - 0x322e], edx
mov word [ebp - 0x322a], dx
lea eax, [ebp - 0x3238]
push eax
call fcn.00401c67
add esp, 0xfffffff4
mov ecx, esp
mov edx, dword [ebp - 0x3238]
mov dword [ecx], edx
mov eax, dword [ebp - 0x3234]
mov dword [ecx + 4], eax
mov edx, dword [ebp - 0x3230]
mov dword [ecx + 8], edx
mov eax, dword [ebp - 0x322c]
mov dword [ecx + 0xc], eax
call fcn.00401e4c
add esp, 0x10
mov word [ebp - 0x3234], ax
mov dword [ebp - 0x20], 0x668a0
cmp dword [ebp - 0xa0], 0
jne 0x51399d
movzx ecx, word [ebp - 0x3234]
shl ecx, 4
lea edx, [ebp + ecx - 0x9c]
sub esp, 0x10
mov eax, esp
mov ecx, dword [edx]
mov dword [eax], ecx
mov ecx, dword [edx + 4]
mov dword [eax + 4], ecx
mov ecx, dword [edx + 8]
mov dword [eax + 8], ecx
mov edx, dword [edx + 0xc]
mov dword [eax + 0xc], edx
sub esp, 0x10
mov eax, esp
mov ecx, dword [ebp - 0x3238]
mov dword [eax], ecx
mov edx, dword [ebp - 0x3234]
mov dword [eax + 4], edx
mov ecx, dword [ebp - 0x3230]
mov dword [eax + 8], ecx
mov edx, dword [ebp - 0x322c]
mov dword [eax + 0xc], edx
call fcn.00401811
add esp, 0x20
push eax
call fcn.005bad40
add esp, 4
mov dword [ebp - 0x323c], eax
cmp dword [ebp - 0x323c], 0xdbba0
jg 0x513913
mov dword [ebp - 0x20], 0xea60
jmp 0x51399b
cmp dword [ebp - 0x323c], 0x36ee80
jg 0x513945
movzx eax, word [ebp - 0x3230]
movzx ecx, word [ebp - 0x3234]
shl ecx, 4
movzx edx, word [ebp + ecx - 0x94]
cmp eax, edx
jl 0x513945
mov dword [ebp - 0x20], 0x1d4c0
jmp 0x51399b
movzx eax, word [ebp - 0x3234]
test eax, eax
jle 0x513971
movzx ecx, word [ebp - 0x3234]
cmp ecx, 6
jge 0x513971
movzx edx, word [ebp - 0x3230]
cmp edx, 0x12
jl 0x513971
mov dword [ebp - 0x20], 0x493e0
jmp 0x51399b
movzx eax, word [ebp - 0x3234]
test eax, eax
je 0x513988
movzx ecx, word [ebp - 0x3234]
cmp ecx, 6
jne 0x51399b
movzx edx, word [ebp - 0x3230]
cmp edx, 0x10
jl 0x51399b
mov dword [ebp - 0x20], 0x493e0
jmp 0x5139a4
mov dword [ebp - 0x20], 0xdbba0
jmp 0x5139ad
mov dword [ebp - 0x20], 0x15f90
push 1
push 0
call fcn.0051acf0
add esp, 8
test eax, eax
jne 0x5139ca
push 0x36ee80
call fcn.00401401
add esp, 4
mov eax, 0x2f9
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x2f9
call fcn.00403166
add esp, 4
xor ecx, ecx
je 0x5139f3
call fcn.0040323d
mov dword [ebp - 0x30a0], eax
cmp dword [ebp - 0x20], 0x1d4c0
jbe 0x513a08
mov dword [ebp - 0x3294], 0x1d4c0
jmp 0x513a11
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x3294], edx
call fcn.0040323d
mov esi, eax
sub esi, dword [ebp - 0x30a0]
call fcn.005b3db0
mov ecx, dword [ebp - 0x3294]
shr ecx, 2
add ecx, 1
xor edx, edx
div ecx
mov eax, dword [ebp - 0x20]
sub eax, edx
cmp esi, eax
jbe 0x513de2
mov ecx, 1
test ecx, ecx
je 0x513de2
mov word [ebp - 0x3270], 0
xor edx, edx
mov dword [ebp - 0x326e], edx
mov dword [ebp - 0x326a], edx
mov dword [ebp - 0x3266], edx
mov word [ebp - 0x3262], dx
mov word [ebp - 0x324c], 0
xor eax, eax
mov dword [ebp - 0x324a], eax
mov dword [ebp - 0x3246], eax
mov dword [ebp - 0x3242], eax
mov word [ebp - 0x323e], ax
mov word [ebp - 0x3260], 0
xor ecx, ecx
mov dword [ebp - 0x325e], ecx
mov dword [ebp - 0x325a], ecx
mov dword [ebp - 0x3256], ecx
mov word [ebp - 0x3252], cx
mov dword [ebp - 0x3250], 0
push 0x308
push 0x6bbce8
lea edx, [ebp - 0x3260]
push edx
call fcn.00402036
add esp, 0xc
mov dword [ebp - 0x3250], 0
lea eax, [ebp - 0x324c]
push eax
lea ecx, [ebp - 0x3270]
push ecx
call fcn.005154d0
add esp, 8
test eax, eax
je 0x513cdd
mov dword [ebp - 0x3274], 0
mov dword [ebp - 0x3278], 0
sub esp, 0x10
mov edx, esp
mov eax, dword [ebp - 0x3270]
mov dword [edx], eax
mov ecx, dword [ebp - 0x326c]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0x3268]
mov dword [edx + 8], eax
mov ecx, dword [ebp - 0x3264]
mov dword [edx + 0xc], ecx
sub esp, 0x10
mov edx, esp
mov eax, dword [ebp - 0x3260]
mov dword [edx], eax
mov ecx, dword [ebp - 0x325c]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0x3258]
mov dword [edx + 8], eax
mov ecx, dword [ebp - 0x3254]
mov dword [edx + 0xc], ecx
call fcn.00401a00
add esp, 0x20
push eax
call fcn.005bad40
add esp, 4
mov dword [ebp - 0x3274], eax
sub esp, 0x10
mov edx, esp
mov eax, dword [ebp - 0x324c]
mov dword [edx], eax
mov ecx, dword [ebp - 0x3248]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0x3244]
mov dword [edx + 8], eax
mov ecx, dword [ebp - 0x3240]
mov dword [edx + 0xc], ecx
sub esp, 0x10
mov edx, esp
mov eax, dword [ebp - 0x3260]
mov dword [edx], eax
mov ecx, dword [ebp - 0x325c]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0x3258]
mov dword [edx + 8], eax
mov ecx, dword [ebp - 0x3254]
mov dword [edx + 0xc], ecx
call fcn.00401a00
add esp, 0x20
push eax
call fcn.005bad40
add esp, 4
mov dword [ebp - 0x3278], eax
mov edx, dword [ebp - 0x3278]
cmp edx, dword [ebp - 0x20]
jle 0x513c00
mov dword [ebp - 0x3250], 1
jmp 0x513cdb
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x329c], eax
mov dword [ebp - 0x3298], 0
fild qword [ebp - 0x329c]
fmul qword [0x629d98]
call fcn.005b6fd0
cmp dword [ebp - 0x3274], eax
jle 0x513cdb
mov dword [ebp - 0x3250], 1
push 1
push 0
call fcn.0051acf0
add esp, 8
test eax, eax
jne 0x513cdb
movzx ecx, word [ebp - 0x325a]
cmp ecx, dword [0x826490]
jne 0x513cce
cmp dword [ebp - 0x308c], 0
jne 0x513cce
call fcn.0040323d
sub eax, dword [0x826494]
cmp eax, 0x927c0
jbe 0x513cce
xor edx, edx
je 0x513ca4
call fcn.0040323d
sub eax, dword [0x826494]
cmp eax, 0x36ee80
jbe 0x513ca2
mov eax, dword [ebp - 0x3274]
push eax
push str.:2:FYI:_SA7_is_not_being_run_at_this_disabled_inactive_store:_lSuccessDif___d
call fcn.004018ca
add esp, 8
jmp 0x513cc4
cmp dword [ebp - 0x3274], 0x493e0
jle 0x513cc4
mov ecx, dword [ebp - 0x3274]
push ecx
push str.:2:Its_been_too_long_since_SA7_succeeded:_lSuccessDif___d
call fcn.004018ca
add esp, 8
call fcn.0040323d
mov dword [0x826494], eax
movzx edx, word [ebp - 0x325a]
mov dword [0x826490], edx
jmp 0x513ce7
mov dword [ebp - 0x3250], 1
call fcn.004010d2
test eax, eax
je 0x513d10
cmp dword [ebp - 0x3250], 0
jne 0x513d06
push str.:1:_RefreshSales___is_being_forced_because_the_time_discrepancy_file_is_broken.
call fcn.004018ca
add esp, 4
mov dword [ebp - 0x3250], 1
cmp dword [ebp - 0x3250], 0
je 0x513dd7
cmp dword [ebp - 0x308c], 0
jne 0x513dd7
push 0x33f
push 0x6bbe08
lea eax, [ebp - 0x324c]
push eax
call fcn.00402036
add esp, 0xc
lea ecx, [ebp - 0x324c]
push ecx
lea edx, [ebp - 0x3270]
push edx
call fcn.00515200
add esp, 8
push 0x826480
lea eax, [ebp - 0x3038]
push eax
mov ecx, dword [ebp - 0x3080]
push ecx
call fcn.005179a0
add esp, 0xc
test eax, eax
je 0x513dd7
push 0x345
push 0x6bbe18
lea edx, [ebp - 0x3270]
push edx
call fcn.00402036
add esp, 0xc
mov eax, dword [ebp - 0x3270]
mov dword [ebp - 0x324c], eax
mov ecx, dword [ebp - 0x326c]
mov dword [ebp - 0x3248], ecx
mov edx, dword [ebp - 0x3268]
mov dword [ebp - 0x3244], edx
mov eax, dword [ebp - 0x3264]
mov dword [ebp - 0x3240], eax
lea ecx, [ebp - 0x324c]
push ecx
lea edx, [ebp - 0x3270]
push edx
call fcn.00515200
add esp, 8
call fcn.0040323d
mov dword [ebp - 0x30a0], eax
mov eax, 0x35a
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x35a
call fcn.00403166
add esp, 4
mov ecx, 0x360
sub ecx, dword [ebp - 0x1c]
mov dword [0x820440], ecx
push 0x360
call fcn.00403166
add esp, 4
call fcn.00514ef0
mov edx, 0x365
sub edx, dword [ebp - 0x1c]
mov dword [0x820440], edx
push 0x365
call fcn.00403166
add esp, 4
cmp dword [ebp - 0x308c], 0
je 0x513e45
call fcn.00514710
mov eax, 0x370
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x370
call fcn.00403166
add esp, 4
cmp dword [0x62a1fc], 0
je 0x513edb
call fcn.0040323d
sub eax, dword [0x826498]
cmp eax, 0xdbba0
jbe 0x513edb
call fcn.0040323d
mov dword [0x826498], eax
call fcn.00401721
test eax, eax
je 0x513edb
cmp dword [0x82649c], 0
jne 0x513ea0
call fcn.0040323d
mov dword [0x82649c], eax
call fcn.0040323d
sub eax, dword [0x82649c]
cmp eax, 0x6ddd00
jbe 0x513edb
call fcn.0040119f
mov dword [ebp - 0x327c], eax
mov ecx, dword [ebp - 0x327c]
push ecx
push str.:1:FYI:_The_server_is_verifying_the_TAMS_server_auto_detected_ip_address:_iResult___d
call fcn.004018ca
add esp, 8
call fcn.0040323d
mov dword [0x82649c], eax
mov edx, 0x385
sub edx, dword [ebp - 0x1c]
mov dword [0x820440], edx
push 0x385
call fcn.00403166
add esp, 4
push 1
push 0
call fcn.0051acf0
add esp, 8
test eax, eax
jne 0x513f17
push 0x36ee80
push 1
push 0
call fcn.00402acc
add esp, 0xc
mov eax, 0x38b
sub eax, dword [ebp - 0x1c]
mov dword [0x820440], eax
push 0x38b
call fcn.00403166
add esp, 4
mov ecx, 0x392
sub ecx, dword [ebp - 0x1c]
mov dword [0x820440], ecx
push 0x392
call fcn.00403166
add esp, 4
cmp dword [ebp - 0x308c], 0
je 0x513f6c
push 0x826480
push 0x2710
call fcn.00403071
add esp, 8
jmp 0x51400d
xor edx, edx
je 0x513f87
push 0x826480
push 0x7d0
call fcn.00403071
add esp, 8
jmp 0x51400d
call fcn.004015eb
cmp eax, 1
jne 0x513fb8
push 0x826480
push 0x4e20
push 0x7d0
call fcn.004031d9
add esp, 8
add eax, 0xea60
push eax
call fcn.00403071
add esp, 8
jmp 0x51400d
call fcn.004015eb
test eax, eax
je 0x513fe8
push 0x826480
push 0x9c40
push 0x2710
call fcn.004031d9
add esp, 8
add eax, 0x7530
push eax
call fcn.00403071
add esp, 8
jmp 0x51400d
push 0x826480
push 0x1b58
push 0x3e8
call fcn.004031d9
add esp, 8
add eax, 0x7530
push eax
call fcn.00403071
add esp, 8
jmp 0x513264
wait
mov dword [ebp - 4], 0xfffffffe
jmp 0x514094
xor edx, edx
je 0x5140d6
call fcn.0040323d
xor edx, edx
mov ecx, 0x5265c00
div ecx
mov dword [ebp - 0x32a4], eax
mov dword [ebp - 0x32a0], 0
fild qword [ebp - 0x32a4]
sub esp, 8
fstp qword [esp]
mov edx, dword [0x820440]
push edx
push str.:0:FYI:_Server_terminated_from_line__d.__TimeGetTime___fdays
call fcn.004018ca
add esp, 0x10
lea eax, [ebp - 0x3038]
push eax
call fcn.00402117
add esp, 4
xor ecx, ecx
je 0x514152
mov dword [ebp - 0x3280], 0
push str._n_nWaiting_up_to_20_seconds_for_async_backup_thread_to_quit...
call fcn.00401c2b
add esp, 4
mov dword [ebp - 0x3280], 1
cmp dword [ebp - 0x3280], 0
jne 0x51413a
push str.:3:WaitForSendProcessedUploadPackagesAsync___FAILED.
call fcn.00401014
add esp, 4
push str.FAILED___
call fcn.00401c2b
add esp, 4
push 0xad9
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x514152
push 0x6bbfa8
call fcn.00401c2b
add esp, 4
push 0x4c6
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0x6bbfac
push 0x3e5
push 0
mov edx, dword [ebp - 0x3024]
push edx
call fcn.00402f09
add esp, 0x10
test eax, eax
je 0x5141c8
mov eax, 1
test eax, eax
je 0x514190
push 0x6bbfbc
push 0
mov ecx, dword [ebp - 0x3024]
push ecx
call fcn.00401a55
add esp, 0xc
push 0x4b
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0x6bbfc4
push 5
mov edx, dword [ebp - 0x3024]
push edx
call fcn.00401a55
add esp, 0xc
push 0xaf
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x3024]
push eax
call fcn.004020d6
add esp, 4
xor ecx, ecx
je 0x5141d1
call fcn.00401c53
call fcn.00402c39
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x24]
xor ecx, ebp
call fcn.005b0290
mov esp, ebp
pop ebp
ret