factor/contrib/process/os-windows.factor

18 lines
420 B
Factor
Raw Normal View History

2006-10-20 17:55:08 -04:00
IN: process
USING: alien compiler io io-internals kernel math parser generic
win32-api ;
2006-10-20 17:55:08 -04:00
: (run-process) ( string flag -- )
>r f swap f f 0 r> f f
"STARTUPINFO" <c-object>
"STARTUPINFO" c-size over set-STARTUPINFO-cb
"PROCESS_INFORMATION" <c-object> CreateProcess
win32-error=0 ;
2006-10-20 17:55:08 -04:00
: run-process ( string -- )
2006-10-20 17:55:08 -04:00
0 (run-process) ;
: run-detached ( string -- )
2006-10-20 18:24:50 -04:00
DETACHED_PROCESS (run-process) ;
2006-10-20 17:55:08 -04:00