Function at 0x47cc70
Capabilities:
Resume thread

Disassembly:
push 0xffffffffffffffff
push 0x556a73
mov eax, dword fs:[0]
push eax
sub esp, 0x80
push ebx
push ebp
push esi
push edi
mov eax, dword [0x660038]
xor eax, esp
push eax
lea eax, [esp + 0x94]
mov dword fs:[0], eax
mov ebp, dword [esp + 0xb0]
mov esi, dword [esp + 0xa4]
mov eax, dword [esp + 0xb4]
push eax
push esi
call fcn.0047d5e0
xor ebx, ebx
mov dword [esp + 0x9c], ebx
push ebx
push ebx
lea edi, [esi + 0x753b8]
mov dword [edi], vtable.ITermStreamSink.0
push 1
push ebx
mov dword [esi], vtable.PrinterPortStream.0
mov dword [edi], vtable.PrinterPortStream.1.0
mov dword [esi + 0x753bc], 0xffffffff
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [esi + 0x753c0], eax
mov dword [esi + 0x753c4], ebx
mov dword [esi + 0x753c8], ebp
mov dword [esi + 0x753cc], ebx
mov dword [esi + 0x753d0], ebx
mov dword [esi + 0x753d4], ebx
mov dword [esi + 0x753d8], ebx
mov dword [esi + 0x753dc], ebx
mov dword [esi + 0x9c4f0], ebx
cmp ebp, ebx
je 0x47cd3e
mov ecx, dword [ebp]
mov edx, dword [ecx + 4]
push ebp
call edx
mov eax, dword [esi + 0x753c8]
push edi
call fcn.004632c0
mov edi, dword [esp + 0xa8]
cmp edi, ebx
jne 0x47cd60
mov dword [esi + 0x1c], 1
mov dword [esp + 0x9c], 0xffffffff
jmp 0x47cee5
lea ecx, [esp + 0x14]
call fcn.004949f0
mov byte [esp + 0x9c], 1
push edi
lea eax, [esp + 0x18]
push str.._1
push eax
call fcn.00495410
add esp, 0xc
push ebx
push 0x40000000
push 3
push ebx
push 3
push 0xc0000000
lea eax, [esp + 0x2c]
call fcn.00407eb0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
or ebp, 0xffffffff
mov dword [esi + 0x753bc], eax
cmp eax, ebp
jne 0x47ce4e
mov ecx, dword [0x676f64]
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [esp + 0x68]
push edx
call fcn.00497730
mov byte [esp + 0x9c], 2
mov eax, dword [0x676f64]
push eax
push 0xe100001a
lea ecx, [esp + 0x34]
push ecx
call fcn.00497730
mov byte [esp + 0x9c], 3
push edi
lea ecx, [esp + 0x30]
call fcn.00497ba0
lea ecx, [esp + 0x60]
call fcn.00497cd0
push eax
lea ecx, [esp + 0x30]
call fcn.00497ba0
push ebx
push ebx
lea ecx, [esp + 0x34]
call fcn.00497cd0
push eax
call sub.mfc90u.dll_AfxMessageBox
mov dword [esi + 0x1c], 1
mov byte [esp + 0x9c], 2
lea ecx, [esp + 0x2c]
call fcn.004978f0
mov byte [esp + 0x9c], 1
lea ecx, [esp + 0x60]
call fcn.004978f0
jmp 0x47cece
push eax
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 2
jne 0x47cea5
mov edx, dword [esi + 0x753bc]
mov eax, dword [esp + 0xac]
push edx
call fcn.0053c190
test al, al
jne 0x47ce77
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi + 0x753bc]
lea eax, [esp + 0x18]
push eax
push ecx
mov dword [esp + 0x20], 4
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], 0x1388
call dword [sym.imp.KERNEL32.dll_SetCommTimeouts]
push ebx
push 4
push ebx
push ebx
push esi
push 0x47d5d0
call sub.mfc90u.dll_AfxBeginThread_1
mov dword [esi + 0x753c4], eax
mov dword [eax + 0x28], ebx
mov eax, dword [esi + 0x753c4]
mov edx, dword [eax + 0x2c]
push edx
call dword [sym.imp.KERNEL32.dll_ResumeThread]
mov byte [esp + 0x9c], bl
lea ecx, [esp + 0x14]
call fcn.00494b70
mov dword [esp + 0x9c], ebp
mov eax, esi
mov ecx, dword [esp + 0x94]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x8c
ret 0x14