Function at 0x401000
Capabilities:
Allocate thread local storage
Delete directory
Identify system language via api

Disassembly:
push 0xd0
push 0
push 0x40c354
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0
call sub.KERNEL32.dll_GetModuleHandleA
mov dword [0x40c358], eax
push 0
push 0x1000
push 0
call sub.KERNEL32.dll_HeapCreate
mov dword [0x40c354], eax
call section..text
call fcn.004089c0
call fcn.004088a8
call fcn.00407220
call fcn.0040677c
call fcn.00406688
call fcn.00406674
call fcn.004065ef
call fcn.004065d8
call fcn.00405131
call fcn.0040472b
call fcn.004044fc
call fcn.00404310
call fcn.00403954
call fcn.0040367d
push dword [0x40c41c]
call fcn.0040451b
push 7
push 0x40b380
lea eax, [0x40c41c]
push eax
push 8
call fcn.00404470
push 0x40c414
push 0x40b378
push 7
push 0x401
push 8
call fcn.00408817
push 0x400
call fcn.00404340
mov dword [0x40c38c], eax
push 8
push dword [0x40c38c]
call sub.KERNEL32.dll_GetUserDefaultLangID
push eax
call sub.KERNEL32.dll_VerLanguageNameA
mov eax, dword [0x40c6a0]
push eax
push eax
mov eax, dword [0x40c6a0]
push eax
push eax
mov eax, dword [0x40c6a0]
push eax
push eax
push 8
push dword [0x40c38c]
call fcn.00404360
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.004030c0
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.004031f0
push 0x40c390
call fcn.00408a10
push dword [0x40c38c]
call fcn.004043b0
push dword [0x40c390]
mov edx, 0x40b32b
pop ecx
call fcn.00408a90
je 0x401235
mov edx, 0x40b119
lea ecx, [0x40c394]
call fcn.00403068
mov edx, 0x40b077
lea ecx, [0x40c398]
call fcn.00403068
mov edx, 0x40b139
lea ecx, [0x40c39c]
call fcn.00403068
mov edx, 0x40b16f
lea ecx, [0x40c3a0]
call fcn.00403068
mov edx, 0x40b215
lea ecx, [0x40c3a4]
call fcn.00403068
mov edx, 0x40b10a
lea ecx, [0x40c3a8]
call fcn.00403068
mov edx, 0x40b2fe
lea ecx, [0x40c3ac]
call fcn.00403068
mov edx, 0x40b245
lea ecx, [0x40c3b0]
call fcn.00403068
mov edx, 0x40b195
lea ecx, [0x40c3b4]
call fcn.00403068
mov edx, 0x40b28b
lea ecx, [0x40c3b8]
call fcn.00403068
mov edx, 0x40b03a
lea ecx, [0x40c3bc]
call fcn.00403068
mov edx, 0x40b20c
lea ecx, [0x40c3c0]
call fcn.00403068
mov edx, 0x40b309
lea ecx, [0x40c3c4]
call fcn.00403068
jmp 0x401305
mov edx, 0x40b125
lea ecx, [0x40c394]
call fcn.00403068
mov edx, 0x40b0cb
lea ecx, [0x40c398]
call fcn.00403068
mov edx, 0x40b1d8
lea ecx, [0x40c39c]
call fcn.00403068
mov edx, 0x40b228
lea ecx, [0x40c3a0]
call fcn.00403068
mov edx, 0x40b2ee
lea ecx, [0x40c3a4]
call fcn.00403068
mov edx, 0x40b014
lea ecx, [0x40c3a8]
call fcn.00403068
mov edx, 0x40b12f
lea ecx, [0x40c3ac]
call fcn.00403068
mov edx, 0x40b338
lea ecx, [0x40c3b0]
call fcn.00403068
mov edx, 0x40b07f
lea ecx, [0x40c3b4]
call fcn.00403068
mov edx, 0x40b0d2
lea ecx, [0x40c3b8]
call fcn.00403068
mov edx, 0x40b2c9
lea ecx, [0x40c3bc]
call fcn.00403068
mov edx, 0x40b203
lea ecx, [0x40c3c0]
call fcn.00403068
mov edx, 0x40b01f
lea ecx, [0x40c3c4]
call fcn.00403068
call fcn.00404227
mov ebx, eax
cmp ebx, 0x32
jge 0x40132c
push 0x10
push dword [0x40c3b8]
push dword [0x40c398]
call fcn.0040368b
jmp 0x401bc8
lea eax, [0x402098]
push eax
call fcn.004040c0
call fcn.00403a92
mov dword [0x40c3cc], eax
push 0
call sub.KERNEL32.dll_GetModuleHandleA
mov dword [0x40c3d0], eax
mov ebx, dword [0x40c3cc]
and ebx, ebx
jle 0x4013d3
mov dword [0x40c3d4], 0
mov ebx, dword [0x40c3cc]
dec ebx
cmp ebx, dword [0x40c3d4]
jl 0x4013d3
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c3d4]
call fcn.00403a44
push 0x40c3d8
call fcn.00408a10
push dword [0x40c3d8]
call sub.SHLWAPI.DLL_PathQuoteSpacesA
mov edx, dword [0x40c3dc]
push dword [0x40c6a0]
call fcn.00408ac0
mov edx, dword [0x40c3d8]
call fcn.00408ac0
mov edx, 0x40b00e
call fcn.00408ac0
push 0x40c3dc
call fcn.00408a10
inc dword [0x40c3d4]
jno 0x401365
push 0x40b0c5
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x4013fe
mov eax, dword [0x40c38c]
mov dword [0x40c3e0], eax
push dword [0x40c3e0]
call fcn.00401c0b
jmp 0x40141e
push 0x10
push dword [0x40c3b4]
push dword [0x40c398]
call fcn.0040368b
push 1
jmp 0x401bcd
push 0x40b0c3
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x401456
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c3c8]
push dword [0x40c38c]
call fcn.00404360
push 0x40c3e4
call fcn.00408a10
jmp 0x401476
push 0x10
push dword [0x40c3b4]
push dword [0x40c398]
call fcn.0040368b
push 1
jmp 0x401bcd
push 0x40b0bb
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x4014aa
mov eax, dword [0x40c38c]
mov dword [0x40c3e8], eax
mov eax, dword [0x40c3c8]
mov dword [0x40c36c], eax
mov eax, dword [0x40c3e8]
mov dword [0x40c360], eax
jmp 0x4014ca
push 0x10
push dword [0x40c3b4]
push dword [0x40c398]
call fcn.0040368b
push 1
jmp 0x401bcd
push 0x40b0c1
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x4014fc
mov eax, dword [0x40c38c]
mov dword [0x40c3ec], eax
mov eax, dword [0x40c3c8]
mov dword [0x40c370], eax
mov eax, dword [0x40c3ec]
mov dword [0x40c364], eax
push 0x40b0bf
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x40152e
mov eax, dword [0x40c38c]
mov dword [0x40c3f0], eax
mov eax, dword [0x40c3c8]
mov dword [0x40c374], eax
mov eax, dword [0x40c3f0]
mov dword [0x40c368], eax
push 0x40b0c7
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x401793
push 0xc80001
push dword [0x40c3c0]
push 0x6e
push 0xc8
push 0
push 0
push 0
call fcn.00405481
push dword [0x40c3c4]
push 0x14
push 0x9e
push 0xf
push 0x15
push 1
call fcn.00404908
push 0x20
push 0x40b00d
push 0x14
push 0x9e
push 0x28
push 0x15
push 2
call fcn.004049e2
push 0x40b288
push 0x14
push 0x4e
push 0x4b
push 0x3d
push 3
call fcn.00404be7
push 4
push 0xd
push 0
call fcn.004054a4
push 2
call fcn.00404c07
call fcn.00405706
push eax
mov ebx, 0x10
cmp ebx, dword [esp]
jne 0x401626
push dword [0x40c388]
call sub.KERNEL32.dll_RemoveDirectoryA
push 0
jmp 0x401bcd
mov ebx, 0x332d
cmp ebx, dword [esp]
jne 0x40166d
call fcn.0040570e
push eax
mov ebx, 4
cmp ebx, dword [esp]
jne 0x40166a
mov eax, dword [0x40c6a0]
push eax
push eax
push 2
call fcn.00404c42
push 0x40c3f4
call fcn.00408a10
push 0
call fcn.00404fa3
add esp, 8
jmp 0x4016b8
pop eax
jmp 0x4016b2
mov ebx, 0x332c
cmp ebx, dword [esp]
jne 0x4016b2
call fcn.0040571d
push eax
mov ebx, 3
cmp ebx, dword [esp]
jne 0x4016b1
mov eax, dword [0x40c6a0]
push eax
push eax
push 2
call fcn.00404c42
push 0x40c3f4
call fcn.00408a10
push 0
call fcn.00404fa3
add esp, 8
jmp 0x4016b8
pop eax
pop eax
jmp 0x4015fc
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c3f4]
call fcn.00403210
push eax
mov eax, dword [0x40c3f4]
push eax
call fcn.00407c10
inc dword [0x40c6a0]
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c3c8]
push dword [0x40c38c]
call fcn.00404360
pop edx
pop ecx
mov dword [0x40c6a0], ecx
add ecx, dword [0x40b388]
add edx, dword [0x40b388]
call fcn.00408a90
jne 0x40173a
push 0x10
push dword [0x40c3a4]
push dword [0x40c398]
call fcn.0040368b
push dword [0x40c388]
call sub.KERNEL32.dll_RemoveDirectoryA
push 1
jmp 0x401bcd
push 0x40b0c9
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x401758
mov eax, dword [0x40c38c]
mov dword [0x40c3f8], eax
push dword [0x40c374]
push dword [0x40c370]
push dword [0x40c36c]
push dword [0x40c3f8]
push dword [0x40c3f0]
push dword [0x40c3ec]
push dword [0x40c3e8]
push dword [0x40c3f4]
push dword [0x40c3d0]
call fcn.00401d66
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c36c]
push dword [0x40c360]
call fcn.00404360
push 0x40c3fc
call fcn.00408a10
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c370]
push dword [0x40c364]
call fcn.00404360
push 0x40c400
call fcn.00408a10
push 0x40b0bd
push dword [0x40c3d0]
call fcn.004020bb
and eax, eax
je 0x401a3c
mov eax, dword [0x40c6a0]
push eax
push eax
push 0
call fcn.00403a44
inc dword [0x40c6a0]
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c3c8]
push dword [0x40c38c]
call fcn.00404360
pop edx
pop ecx
mov dword [0x40c6a0], ecx
add ecx, dword [0x40b388]
add edx, dword [0x40b388]
call fcn.00408a90
je 0x40184b
mov ebx, dword [0x40c3cc]
cmp ebx, 1
jne 0x40184b
mov eax, 1
jmp 0x40184d
xor eax, eax
and eax, eax
je 0x401a3c
mov eax, dword [0x40c6a0]
push eax
push eax
mov eax, dword [0x40c6a0]
push eax
push eax
call fcn.00406fb6
inc dword [0x40c6a0]
push dword [0x40c3bc]
mov edx, dword [0x40b388]
add dword [esp + 4], edx
call fcn.004036e1
push 0x40c404
call fcn.00408a10
mov edx, dword [0x40c404]
xor ecx, ecx
call fcn.00408a90
jne 0x4019ec
mov edx, dword [0x40c404]
push dword [0x40c6a0]
call fcn.00408ac0
push 0x40c380
call fcn.00408a10
mov edx, dword [0x40c400]
xor ecx, ecx
call fcn.00408a90
jne 0x4018d5
push dword [0x40c400]
call fcn.00402122
push dword [0x40c3e4]
push 1
call fcn.00407380
and eax, eax
je 0x4019be
push 1
call fcn.004071b0
push dword [0x40c6a0]
push 0x24
mov edx, dword [0x40c3ac]
push dword [0x40c6a0]
call fcn.00408ac0
mov edx, 0x40b010
call fcn.00408ac0
mov edx, dword [0x40c3e4]
call fcn.00408ac0
mov edx, 0x40b010
call fcn.00408ac0
mov edx, dword [0x40c3b0]
call fcn.00408ac0
inc dword [0x40c6a0]
push dword [0x40c3a8]
mov edx, dword [0x40b388]
add dword [esp + 4], edx
call fcn.0040368b
pop dword [0x40c6a0]
mov dword [0x40c408], eax
mov ebx, dword [0x40c408]
cmp ebx, 7
jne 0x4019be
mov eax, dword [0x40c6a0]
push eax
push eax
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c6a0]
call fcn.00403aa5
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.00406ff6
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.00407071
pop dword [0x40c6a0]
push dword [0x40c388]
call sub.KERNEL32.dll_RemoveDirectoryA
push 0
jmp 0x401bcd
push dword [0x40c3e4]
push 1
call fcn.00407360
and eax, eax
je 0x4019ec
push dword [0x40c3fc]
push 1
call fcn.004073a0
push 1
call fcn.004071b0
mov eax, dword [0x40c6a0]
push eax
push eax
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c6a0]
call fcn.00403aa5
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.00406ff6
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.00407071
pop dword [0x40c6a0]
push dword [0x40c388]
call sub.KERNEL32.dll_RemoveDirectoryA
push 0
jmp 0x401bcd
mov edx, dword [0x40c388]
push dword [0x40c6a0]
call fcn.00408ac0
mov edx, 0x40b0b9
call fcn.00408ac0
mov edx, dword [0x40c3e4]
call fcn.00408ac0
push 0x40c3e4
call fcn.00408a10
push dword [0x40c3e4]
push 1
call fcn.00407360
and eax, eax
je 0x401a9c
push dword [0x40c3fc]
push 1
call fcn.004073a0
push 1
call fcn.004071b0
jmp 0x401ad7
push dword [0x40c3e4]
call fcn.00407081
call fcn.0040202f
push 0x10
push dword [0x40c3b4]
push dword [0x40c398]
call fcn.0040368b
push dword [0x40c388]
call sub.KERNEL32.dll_RemoveDirectoryA
push 1
jmp 0x401bcd
mov edx, dword [0x40c400]
xor ecx, ecx
call fcn.00408a90
jne 0x401af1
push dword [0x40c400]
call fcn.00402122
push dword [0x40c6a0]
push 0x64
push dword [0x40c380]
mov edx, dword [0x40c3dc]
push dword [0x40c6a0]
call fcn.00408ac0
mov edx, dword [0x40c384]
call fcn.00408ac0
inc dword [0x40c6a0]
push dword [0x40c3e4]
mov edx, dword [0x40b388]
add dword [esp + 4], edx
call fcn.00403f4a
pop dword [0x40c6a0]
mov dword [0x40c40c], eax
push dword [0x40c40c]
call fcn.00403f84
push dword [0x40c40c]
call fcn.00403f92
mov dword [0x40c410], eax
push dword [0x40c40c]
call fcn.00403fb0
call fcn.0040202f
push dword [0x40c3e4]
call fcn.00407081
mov eax, dword [0x40c6a0]
push eax
push eax
mov eax, dword [0x40c6a0]
push eax
push eax
push dword [0x40c6a0]
call fcn.00403aa5
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.00406ff6
mov edx, dword [0x40b388]
add dword [esp], edx
call fcn.00407071
pop dword [0x40c6a0]
push dword [0x40c388]
call sub.KERNEL32.dll_RemoveDirectoryA
push dword [0x40c410]
jmp 0x401bcd
push 0
call 0x401be2
push dword [0x40c354]
call sub.KERNEL32.dll_HeapDestroy
call sub.KERNEL32.dll_ExitProcess
call fcn.00404064
call fcn.00404210
call fcn.00404330
call fcn.0040479b
call fcn.00405091
call fcn.00406646
call fcn.0040680a
call fcn.00407210
ret