Function at 0x10180fc0
Capabilities:
Create pipe

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
mov eax, dword [0x10254be4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
cmp dword [0x1026cda4], 0
jne 0x10180ff6
push 0x80
push 0x10000
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__pipe]
add esp, 0xc
jmp 0x101812dc
push 0xd
push str..pipe_ruby
lea ecx, [ebp - 0x24]
push ecx
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
mov edx, dword [0x1026d890]
mov dword [ebp - 0x40], edx
mov eax, dword [0x1026d890]
add eax, 1
mov dword [0x1026d890], eax
mov ecx, dword [ebp - 0x40]
push ecx
push 8
call sym.ruby.dll_rb_w32_getpid
push eax
push 8
push str._.x__.lx
push 0x12
lea edx, [ebp - 0x17]
push edx
call sym.ruby.dll_rb_w32_snprintf
add esp, 0x1c
mov dword [ebp - 0x50], 0xc
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x48], 0
lea eax, [ebp - 0x50]
push eax
push 0
push 0x10000
push 0x10000
push 2
push 0
push 0x40000003
lea ecx, [ebp - 0x24]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateNamedPipeA]
mov dword [ebp - 0x38], eax
xor edx, edx
jne 0x10181055
cmp dword [ebp - 0x38], 0xffffffff
jne 0x101810c6
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x44], eax
cmp dword [ebp - 0x44], 0xe7
jne 0x101810a5
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [eax], 0x18
jmp 0x101810be
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call sym.ruby.dll_rb_w32_map_errno
add esp, 4
mov esi, eax
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [eax], esi
or eax, 0xffffffff
jmp 0x101812dc
push 0
push 0x40000000
push 3
lea eax, [ebp - 0x50]
push eax
push 0
push 0xc0000000
lea ecx, [ebp - 0x24]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x3c], eax
xor edx, edx
jne 0x101810c6
cmp dword [ebp - 0x3c], 0xffffffff
jne 0x1018111c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call sym.ruby.dll_rb_w32_map_errno
add esp, 4
mov esi, eax
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [eax], esi
mov eax, dword [ebp - 0x38]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or eax, 0xffffffff
jmp 0x101812dc
mov dword [ebp - 0x2c], 0
push 0
push 0
push 4
push 0
push 0
push 0
push 0x10253f5c
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x34], eax
push 0
mov ecx, dword [ebp - 0x34]
push ecx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__open_osfhandle]
add esp, 8
mov dword [ebp - 0x28], eax
mov edx, dword [ebp - 0x34]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x28], 0xffffffff
jne 0x10181188
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [eax], 0x18
mov eax, dword [ebp - 0x3c]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x38]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x2c], 0xffffffff
jmp 0x101811d8
mov edx, dword [ebp - 0x28]
push edx
call fcn.10186ec0
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebp - 0x28]
push eax
call fcn.10186ec0
add esp, 4
mov ecx, dword [ebp - 0x38]
mov dword [eax + 0x18], ecx
mov edx, dword [ebp - 0x28]
push edx
call fcn.10186ec0
add esp, 4
mov byte [eax + 0x28], 0x19
mov eax, dword [ebp - 0x28]
push eax
call fcn.10186ec0
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor ecx, ecx
jne 0x1018111c
xor edx, edx
jne 0x1018111c
cmp dword [ebp - 0x2c], 0
je 0x101811ee
mov eax, dword [ebp - 0x2c]
jmp 0x101812dc
push 0
push 0
push 4
push 0
push 0
push 0
push 0x10253f60
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x34], eax
push 0
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__open_osfhandle]
add esp, 8
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp - 0x34]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x30], 0xffffffff
jne 0x10181249
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [eax], 0x18
mov edx, dword [ebp - 0x3c]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x2c], 0xffffffff
jmp 0x10181299
mov eax, dword [ebp - 0x30]
push eax
call fcn.10186ec0
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [ebp - 0x30]
push ecx
call fcn.10186ec0
add esp, 4
mov edx, dword [ebp - 0x3c]
mov dword [eax + 0x18], edx
mov eax, dword [ebp - 0x30]
push eax
call fcn.10186ec0
add esp, 4
mov byte [eax + 0x28], 0x19
mov ecx, dword [ebp - 0x30]
push ecx
call fcn.10186ec0
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor edx, edx
jne 0x101811ee
xor eax, eax
jne 0x101811ee
cmp dword [ebp - 0x2c], 0
je 0x101812b8
mov ecx, dword [ebp - 0x28]
push ecx
call sym.ruby.dll_rb_w32_close
add esp, 4
mov eax, dword [ebp - 0x2c]
jmp 0x101812dc
mov edx, 4
imul eax, edx, 0
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x28]
mov dword [ecx + eax], edx
mov eax, 4
shl eax, 0
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x30]
mov dword [ecx + eax], edx
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101949b1
mov esp, ebp
pop ebp
ret