Function at 0x40a0e0
Capabilities:
Get common file path

Disassembly:
push edi
push esi
sub esp, 0x208
lea esi, [esp + 0x104]
push esi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
dec eax
cmp eax, 0x103
jae 0x40a135
mov edi, esp
push edi
push 0
push str.fastboot
push esi
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
je 0x40a146
push str.wbTD
push edi
call sub.msvcrt.dll_fopen
add esp, 8
push eax
call sub.msvcrt.dll__fileno_1
add esp, 0x20c
pop esi
pop edi
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetTempPath_failed__error__ld
call fcn.00412d70
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetTempFileName_failed__error__ld
call fcn.00412d70
nop word [eax + eax]
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x20
mov edi, dword [ebp + 8]
cmp byte [edi + 7], 0xff
jne 0x40a2fc
cmp byte [edi + 8], 0x42
jne 0x40a2fc
cmp byte [edi + 9], 3
jne 0x40a2fc
lea ebx, [edi + 0xd]
mov dword [esp + 4], 0
mov dword [esp], 0
mov dword [esp + 8], 0
push ebx
call sub.msvcrt.dll_strlen
add esp, 4
cmp eax, 0xfffffff0
jae 0x40a309
mov ecx, eax
cmp eax, 0xb
jae 0x40a1d1
mov eax, ecx
lea esi, [esp + 1]
add al, cl
test ecx, ecx
mov byte [esp], al
jne 0x40a1fe
jmp 0x40a20d
mov dword [esp + 0xc], ebx
mov ebx, ecx
add ebx, 0x10
and ebx, 0xfffffff0
push ebx
mov esi, ecx
call fcn.0040bb60
mov ecx, esi
add esp, 4
or ebx, 1
mov dword [esp + 8], eax
mov esi, eax
mov dword [esp], ebx
mov ebx, dword [esp + 0xc]
mov dword [esp + 4], ecx
push ecx
push ebx
push esi
mov ebx, ecx
call sub.msvcrt.dll_memcpy
mov ecx, ebx
add esp, 0xc
mov byte [esi + ecx], 0
cmp byte [edi + 0xc], 0
jne 0x40a26d
lea eax, [esp + 0x10]
push eax
call fcn.0043bf90
add esp, 4
test byte [esp], 1
jne 0x40a232
mov word [esp], 0
jmp 0x40a25a
mov eax, dword [esp + 8]
mov byte [eax], 0
mov dword [esp + 4], 0
test byte [esp], 1
je 0x40a25a
push dword [esp + 8]
call fcn.0040bd10
add esp, 4
mov dword [esp], 0
mov eax, dword [esp + 0x18]
movsd xmm0, qword [esp + 0x10]
mov dword [esp + 8], eax
movsd qword [esp], xmm0
mov cl, byte [esp]
mov eax, dword [esp + 8]
lea esi, [esp + 1]
and cl, 1
mov edx, eax
cmove edx, esi
cmp byte [edx], 0
jne 0x40a29b
mov ecx, esp
push str.____________
call fcn.004e7f50
mov cl, byte [esp]
mov eax, dword [esp + 8]
and cl, 1
test cl, cl
cmove eax, esi
cmp byte [0x53c4e6], 0
je 0x40a2d2
push eax
push str.__22s_fastboot
call fcn.004cb140
add esp, 8
add edi, 0x10d
push edi
call sub.msvcrt.dll_strlen
add esp, 4
test eax, eax
je 0x40a2e0
push edi
push 0x5130af
jmp 0x40a2d8
push eax
push str._s_tfastboot
call fcn.004cb140
add esp, 8
push 0xa
call sub.msvcrt.dll_putchar
add esp, 4
test byte [esp], 1
je 0x40a2fc
push dword [esp + 8]
call fcn.0040bd10
add esp, 4
mov eax, 0xffffffff
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov ecx, esp
call fcn.004d1480
push ebx
push edi
push esi
mov edi, dword [esp + 0x10]
mov esi, 0xffffffff
cmp byte [edi + 7], 0xff
jne 0x40a35f
cmp byte [edi + 8], 0x42
jne 0x40a35f
cmp byte [edi + 9], 3
jne 0x40a35f
mov ebx, dword [0x53c4e0]
test ebx, ebx
je 0x40a35d
lea eax, [edi + 0xd]
push eax
push ebx
call sub.msvcrt.dll_strcmp
add esp, 8
test eax, eax
je 0x40a35d
add edi, 0x10d
push edi
push ebx
call sub.msvcrt.dll_strcmp
add esp, 8
test eax, eax
jne 0x40a35f
xor esi, esi
mov eax, esi
pop esi
pop edi
pop ebx
ret