Function at 0x566060
Capabilities:
Check mutex on windows
Enumerate gui resources

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5ab530
mov eax, dword fs:[0]
push eax
sub esp, 0x5c
mov eax, dword [0x5f300c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov ebx, dword [ebp + 8]
lea ecx, [edi + 0xb0c]
push 0
push str.save.session
mov dword [ebp - 0x64], ebx
call fcn.00528190
test eax, eax
jne 0x5660d3
push eax
push 0x5d714c
lea ecx, [edi + 0xb0c]
call fcn.00528190
test eax, eax
jne 0x5660d3
push eax
push str.save.recent
lea ecx, [edi + 0xb0c]
call fcn.00528190
test eax, eax
je 0x5660df
push 0x5d716c
mov ecx, edi
call fcn.00543660
mov edx, ebx
lea ecx, [ebp - 0x40]
call fcn.00565e90
push 0
lea eax, [ebp - 0x40]
mov dword [ebp - 4], 0
push eax
mov ecx, edi
call fcn.00540200
mov byte [ebp - 0x59], al
test al, al
jne 0x56622d
push 0
push str.check.if.already.open
lea ecx, [edi + 0xb0c]
call fcn.00528190
test eax, eax
je 0x56622d
push 0x1a
lea ebx, [edi + 0x12f8]
push str.SciTE_UniqueInstanceMutex_
mov ecx, ebx
call fcn.0040acf0
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.USER32.dll_GetThreadDesktop]
lea ecx, [ebp - 0x60]
mov dword [ebp - 0x68], eax
push ecx
push 0
push 0
push 2
push eax
mov dword [ebp - 0x60], 0
call dword [sym.imp.USER32.dll_GetUserObjectInformationW]
test eax, eax
jne 0x5661d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x5661d1
push ecx
push dword [ebp - 0x60]
xor eax, eax
mov dword [ebp - 0x18], 0
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
call fcn.0040ab90
mov byte [ebp - 4], 1
lea eax, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
jb 0x56619d
mov eax, dword [ebp - 0x28]
push 0
push dword [ebp - 0x60]
push eax
push 2
push dword [ebp - 0x68]
call dword [sym.imp.USER32.dll_GetUserObjectInformationW]
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
jb 0x5661ba
mov eax, dword [ebp - 0x28]
push dword [ebp - 0x18]
mov ecx, ebx
push eax
call fcn.00519fc0
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0
call fcn.0040ab30
mov eax, dword [edi + 0x12ec]
mov byte [eax + 0x88c], 1
cmp dword [ebx + 0x14], 8
jb 0x5661e6
mov ebx, dword [ebx]
push ebx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi + 0x12f4], eax
call ebx
cmp eax, 0xb7
je 0x566211
call ebx
cmp eax, 5
je 0x566211
xor al, al
jmp 0x566213
mov al, 1
mov ebx, dword [ebp - 0x64]
mov byte [edi + 0x1310], al
test al, al
je 0x56622d
mov eax, dword [edi + 0x12ec]
mov byte [eax + 0x88c], 0
mov ecx, edi
call fcn.00565ac0
cmp byte [ebp - 0x59], 0
je 0x566258
push 1
lea eax, [ebp - 0x40]
mov ecx, edi
push eax
call fcn.00540200
mov eax, dword [edi]
mov ecx, edi
push 0
call dword [eax + 0xa4]
jmp 0x566321
push 0
push 0x5d71bc
lea ecx, [edi + 0xb0c]
call fcn.00528190
test eax, eax
je 0x566346
cmp byte [edi + 0x1310], 0
lea esi, [edi + 0x12ec]
je 0x566346
cmp dword [esi + 4], 0
je 0x566346
push esi
push 0x577f70
call dword [sym.imp.USER32.dll_EnumWindows]
cmp dword [esi + 0x28], 0
je 0x566346
push ebx
lea ecx, [ebp - 0x58]
call fcn.00519f70
lea edx, [ebp - 0x58]
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x28]
call fcn.00560610
mov byte [ebp - 4], 3
cmp dword [eax + 0x14], 0x10
jb 0x5662c9
mov eax, dword [eax]
push eax
mov ecx, esi
call fcn.00577d50
mov edx, dword [ebp - 0x14]
cmp edx, 0x10
jb 0x566307
mov ecx, dword [ebp - 0x28]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x5662fd
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x5662fd
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push edx
push ecx
call fcn.0059e222
add esp, 8
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
call fcn.0040ab30
push 0
call dword [sym.imp.USER32.dll_PostQuitMessage]
mov eax, dword [edi + 0x7b0]
test eax, eax
je 0x56633a
push eax
call dword [sym.imp.USER32.dll_DestroyWindow]
mov dword [edi + 0x7b0], 0
jmp 0x5663ac
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0x158]
mov esi, dword [sym.imp.USER32.dll_ShowWindow]
push 4
push dword [edi + 0x7b0]
call esi
mov edx, dword [edi + 0xc74]
test edx, edx
je 0x566375
mov ecx, edi
call fcn.00563920
push edx
push eax
call esi
push 1
lea eax, [ebp - 0x40]
mov ecx, edi
push eax
call fcn.00540200
mov esi, dword [sym.imp.USER32.dll_InvalidateRect]
push 0
push 0
push dword [edi + 0x7b0]
call esi
push 0
push 0
push dword [edi + 0x7c0]
call esi
push 0
push 0
push dword [edi + 0x7d4]
call esi
lea ecx, [ebp - 0x40]
call fcn.0040ab30
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0059df64
mov esp, ebp
pop ebp
ret 4