Function at 0x404d99
Capabilities:
Delete file
Enumerate files on windows

Disassembly:
mov eax, 0x41201c
call fcn.004114d0
sub esp, 0x500
mov eax, dword [0x4211a4]
push ebx
xor ebx, ebx
push esi
xor eax, ebp
mov dword [ebp - 0x10], eax
push edi
mov esi, ecx
mov dword [ebp - 0x4d8], ebx
mov dword [ebp - 0x4d4], ebx
mov dword [ebp - 0x4d0], ebx
mov dword [ebp - 4], ebx
lea ecx, [ebp - 0x274]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
mov byte [ebp - 4], 1
lea eax, [esi + 0xf8]
push eax
lea ecx, [ebp - 0x500]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
mov byte [ebp - 4], 2
lea eax, [ebp - 0x274]
push eax
lea eax, [ebp - 0x500]
push eax
call fcn.00402feb
pop ecx
pop ecx
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x500]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
lea ecx, [ebp - 0x274]
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
mov dword [ebp - 0x4cc], eax
xor eax, eax
cmp dword [esi + 0xe4], 0xffffffff
mov word [ebp - 0x218], bx
mov ecx, 0x81
lea edi, [ebp - 0x216]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
jne 0x404e70
push dword [ebp - 0x4cc]
lea eax, [ebp - 0x218]
push str._s.log
push 0x104
push eax
call dword [sym.imp.MSVCR71.dll__snwprintf]
add esp, 0x10
jmp 0x404e9d
mov ecx, esi
call fcn.004019ab
push eax
push str.TSLOG
push dword [ebp - 0x4cc]
lea eax, [ebp - 0x218]
push str._s_s._s__..log
push 0x104
push eax
call dword [sym.imp.MSVCR71.dll__snwprintf]
add esp, 0x18
lea eax, [ebp - 0x4c4]
push eax
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
lea ecx, [ebp - 0x258]
mov dword [ebp - 0x4c8], eax
call fcn.00401c9b
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x234]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
mov byte [ebp - 4], 4
cmp dword [ebp - 0x4c8], 0xffffffff
je 0x405045
jmp 0x404ee7
xor ebx, ebx
push dword [ebp - 0x4cc]
lea ecx, [ebp - 0x234]
call dword [sym.imp.MSVCP71.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_wchar_t_const__]
lea eax, [ebp - 0x498]
push eax
lea ecx, [ebp - 0x234]
call dword [0x4142f4]
cmp dword [esi + 0xe4], 0xffffffff
lea ecx, [ebp - 0x234]
jne 0x404f2d
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x40502a
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
push eax
mov ecx, esi
call fcn.00401d4e
mov ecx, eax
cmp ecx, ebx
mov dword [ebp - 0x4e0], ecx
jl 0x40502a
mov ebx, dword [ebp - 0x4d8]
mov eax, dword [ebp - 0x4d4]
cmp ebx, eax
je 0x404fac
cmp ecx, dword [ebx]
je 0x404f68
add ebx, 0x28
cmp ebx, eax
jne 0x404f5b
jmp 0x404fa4
lea edi, [ebx + 4]
mov eax, dword [edi + 0x20]
cmp eax, dword [ebp - 0x4ac]
ja 0x404f83
jne 0x404fa4
mov eax, dword [edi + 0x1c]
cmp eax, dword [ebp - 0x4b0]
jbe 0x404fa4
lea eax, [ebp - 0x234]
mov ecx, edi
push eax
call dword [sym.imp.MSVCP71.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__]
mov eax, dword [ebp - 0x4b0]
mov dword [edi + 0x1c], eax
mov eax, dword [ebp - 0x4ac]
mov dword [edi + 0x20], eax
cmp ebx, dword [ebp - 0x4d4]
jne 0x40502a
lea eax, [ebp - 0x234]
push eax
lea ecx, [ebp - 0x258]
call dword [sym.imp.MSVCP71.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__]
mov eax, dword [ebp - 0x4b0]
mov dword [ebp - 0x23c], eax
mov eax, dword [ebp - 0x4ac]
sub esp, 0x24
mov dword [ebp - 0x238], eax
lea eax, [ebp - 0x258]
mov ecx, esp
mov dword [ebp - 0x4e4], esp
push eax
call fcn.00401ce6
mov byte [ebp - 4], 5
push dword [ebp - 0x4e0]
lea eax, [ebp - 0x50c]
push eax
mov byte [ebp - 4], 4
call fcn.00402bda
add esp, 0x2c
mov byte [ebp - 4], 6
push eax
lea ecx, [ebp - 0x4dc]
call fcn.00404ce8
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x50c]
call fcn.00401d28
lea eax, [ebp - 0x4c4]
push eax
push dword [ebp - 0x4c8]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x404ee5
push dword [ebp - 0x4c8]
call dword [sym.imp.KERNEL32.dll_FindClose]
lea ecx, [ebp - 0x4dc]
call fcn.00401e47
mov ebx, eax
mov eax, dword [esi + 0xe8]
xor ecx, ecx
cmp eax, 0xffffffff
sete cl
dec ecx
mov edi, ecx
lea ecx, [ebp - 0x218]
push ecx
push eax
mov dword [ebp - 0x4cc], edi
add edi, ebx
push edi
push dword [esi + 0xe4]
push str.DeleteLogFile__MaxCountOfHistroyProcess_:__d__CurrentHistroyProcess_:__d__CurrentLogFileHandle_:_0x_08x__PathWildcard_:__s
push esi
call fcn.00401de6
add esp, 0x18
cmp edi, dword [esi + 0xe4]
jle 0x405109
mov edi, dword [ebp - 0x4d8]
push 0x401e1b
push dword [ebp - 0x4d4]
push edi
call fcn.00404d2d
mov eax, dword [ebp - 0x4cc]
sub eax, dword [esi + 0xe4]
and dword [ebp - 0x4c8], 0
add eax, ebx
add esp, 0xc
test eax, eax
jle 0x405109
mov eax, dword [edi]
push eax
push eax
push str.DeleteLogFiles__AllFilesOfPid_:__lu_0x_08x_
push esi
call fcn.00401de6
add esp, 0x10
push dword [edi]
mov ecx, esi
call fcn.0040345f
mov eax, dword [ebp - 0x4cc]
sub eax, dword [esi + 0xe4]
inc dword [ebp - 0x4c8]
add eax, ebx
add edi, 0x28
cmp dword [ebp - 0x4c8], eax
jl 0x4050cf
lea ecx, [ebp - 0x4dc]
call fcn.00404be3
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x234]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x258]
call fcn.00401cc2
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x274]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4dc]
call fcn.00404be3
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x10]
pop edi
xor eax, eax
pop esi
xor ecx, ebp
inc eax
pop ebx
call fcn.004113e5
leave
ret