Function at 0x10030180
Capabilities:
Check if file exists
Delete file
Get file attributes
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1014283e
mov eax, dword fs:[0]
push eax
sub esp, 0xb0
mov eax, dword [0x1030e040]
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 eax, dword [edi + 0x68]
test eax, eax
je 0x10030217
cmp dword [edi + 0xfc], 0
je 0x100301e2
mov ecx, dword [edi + 0xfc]
mov dword [ebp - 0x44], eax
test ecx, ecx
jne 0x100301d3
call dword [sym.imp.MSVCP140.dll_void___cdecl_std::_Xbad_function_call_void_]
mov eax, dword [ecx]
lea edx, [ebp - 0x44]
push edx
lea esi, [edi + 0x6c]
push esi
call dword [eax + 8]
jmp 0x100301e5
lea esi, [edi + 0x6c]
push dword [edi + 0x68]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 4
mov dword [edi + 0x68], 0
cmp dword [edi + 0x124], 0
je 0x10030217
mov ecx, dword [edi + 0x124]
test ecx, ecx
jne 0x10030211
call dword [sym.imp.MSVCP140.dll_void___cdecl_std::_Xbad_function_call_void_]
mov eax, dword [ecx]
push esi
call dword [eax + 8]
mov esi, dword [edi + 0x58]
test esi, esi
je 0x100302fe
lea eax, [edi + 0x3c]
lea ebx, [esi - 1]
mov edx, eax
push ebx
lea ecx, [ebp - 0x40]
call fcn.10030740
add esp, 4
mov dword [ebp - 4], 0
lea eax, [ebp - 0x40]
cmp dword [ebp - 0x2c], 0xf
cmova eax, dword [ebp - 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x100302e8
push esi
lea edx, [edi + 0x3c]
lea ecx, [ebp - 0x28]
call fcn.10030740
mov byte [ebp - 4], 1
lea eax, [ebp - 0x28]
cmp dword [ebp - 0x14], 0xf
mov esi, dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
cmova eax, dword [ebp - 0x28]
push eax
call esi
cmp dword [ebp - 0x14], 0xf
lea ecx, [ebp - 0x28]
lea eax, [ebp - 0x40]
cmova ecx, dword [ebp - 0x28]
cmp dword [ebp - 0x2c], 0xf
push ecx
cmova eax, dword [ebp - 0x40]
push eax
call dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_rename]
add esp, 0x10
test eax, eax
je 0x100302dc
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [ebp - 0x14], 0xf
lea eax, [ebp - 0x28]
cmova eax, dword [ebp - 0x28]
push eax
call esi
cmp dword [ebp - 0x14], 0xf
lea ecx, [ebp - 0x28]
lea eax, [ebp - 0x40]
cmova ecx, dword [ebp - 0x28]
cmp dword [ebp - 0x2c], 0xf
push ecx
cmova eax, dword [ebp - 0x40]
push eax
call dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_rename]
add esp, 0xc
test eax, eax
jne 0x10030332
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x28]
call fcn.100126b0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x40]
call fcn.100126b0
mov esi, ebx
jmp 0x1003021a
cmp dword [edi + 0x7c], 0
lea ecx, [edi + 0x60]
je 0x100303b3
push 1
lea eax, [ecx + 0xc]
push eax
call fcn.100332a0
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.1013cfec
mov esp, ebp
pop ebp
ret
lea ecx, [edi + 0x60]
push ecx
call fcn.10033620
mov dword [edi + 0x5c], 0
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
lea edx, [ebp - 0x28]
lea ecx, [ebp - 0x5c]
mov edi, dword [eax]
call fcn.10033850
mov esi, eax
mov byte [ebp - 4], 2
lea edx, [ebp - 0x40]
lea ecx, [ebp - 0x74]
call fcn.10033850
mov byte [ebp - 4], 3
mov edx, str.rotating_file_sink:_failed_renaming
push eax
lea ecx, [ebp - 0x8c]
call fcn.1002bf70
mov byte [ebp - 4], 4
mov edx, eax
push str._to
lea ecx, [ebp - 0xa4]
call fcn.1002c190
mov byte [ebp - 4], 5
mov edx, eax
push esi
lea ecx, [ebp - 0xbc]
call fcn.10032fc0
add esp, 0xc
mov byte [ebp - 4], 6
mov edx, edi
mov ecx, eax
call fcn.1003b290
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x44], esp
push str.Failed_re_opening_file___was_not_opened_before
call fcn.10012b20
mov dword [ebp - 4], 7
mov dword [ebp - 4], 0xffffffff
call fcn.10033740
int3