Function at 0x445b30
Capabilities:
Check mutex on windows
Query environment variable
Set environment variable

Disassembly:
push ebp
lea ebp, [esp - 0xc8]
sub esp, 0xc8
push 0xffffffffffffffff
push 0x46ac1b
mov eax, dword fs:[0]
push eax
sub esp, 0x24
mov eax, dword [0x485d30]
xor eax, ebp
mov dword [ebp + 0xc4], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov ebx, ecx
mov dword [ebp - 0x14], ebx
mov dword [ebx], 0
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push str.1830B7BD_F7A3_4c4d_989B_C004DE465EDE
push str._s__u
mov dword [ebp - 0x18], eax
lea eax, [ebp]
push 0x40
push eax
call fcn.00451a6c
add esp, 0x14
lea edx, [ebp]
push edx
push 1
xor ecx, ecx
xor esi, esi
push esi
mov word [ebp + 0x80], cx
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov edi, eax
mov dword [ebp - 0x20], edi
test edi, edi
je 0x445c45
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x445bd4
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0x1f
lea eax, [ebp + 0x84]
push eax
push str.1830B7BD_F7A3_4c4d_989B_C004DE465EDE
mov dword [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x445c6c
xor ecx, ecx
mov word [ebp + eax*2 + 0x84], cx
lea edx, [ebp - 0x2c]
push edx
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp + 0x84]
push str._x:_x
push ecx
call fcn.004524c5
add esp, 0x10
cmp eax, 2
jne 0x445c6c
mov edx, dword [ebp - 0x18]
cmp dword [ebp - 0x28], edx
jne 0x445c6c
mov eax, dword [ebp - 0x2c]
mov dword [ebx], eax
mov eax, dword [ebx]
inc dword [eax + 0x5bc]
push edi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
test esi, esi
jne 0x445c45
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0xc4]
xor ecx, ebp
call fcn.0044e04c
add ebp, 0xc8
mov esp, ebp
pop ebp
ret
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
test eax, eax
je 0x445c87
push 0x5c0
push esi
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
mov dword [ebp - 0x30], esi
mov byte [ebp - 4], 1
test esi, esi
je 0x445c9c
push edi
mov ecx, esi
call fcn.00445a10
jmp 0x445c9e
xor eax, eax
mov byte [ebp - 4], 0
mov dword [ebx], eax
test eax, eax
jne 0x445cbd
push 0x47e760
lea ecx, [ebp - 0x1c]
push ecx
mov dword [ebp - 0x1c], 1
call fcn.0044ef3c
mov edx, dword [ebp - 0x18]
push eax
push edx
lea eax, [ebp + 0x84]
push str._x:_x
push eax
mov esi, 1
call fcn.00451b3f
add esp, 0x10
lea ecx, [ebp + 0x84]
push ecx
push str.1830B7BD_F7A3_4c4d_989B_C004DE465EDE
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
test eax, eax
jne 0x445c2b
push 0x47e760
lea edx, [ebp - 0x24]
push edx
mov dword [ebp - 0x24], 3
call fcn.0044ef3c
push 0
push str.1830B7BD_F7A3_4c4d_989B_C004DE465EDE
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov edi, dword [ebp - 0x20]
push edi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov esi, dword [ebp - 0x14]
mov ecx, dword [esi]
test ecx, ecx
je 0x445d39
push 1
call fcn.00445ad0
mov dword [esi], 0
jmp 0x445d40
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 0x445d46
ret