[haskell-cafe] Finding a PID in Windows
bulat.ziganshin at gmail.com
Sun Feb 22 11:52:21 EST 2009
Sunday, February 22, 2009, 7:38:31 PM, you wrote:
> In Linux, if you want to find the PID of a process, you use getProcessID from
"The GetCurrentProcessId function returns the process identifier of the calling process.
you need to make FFI import yourself. look Win32 package sources for
examples of how to do it. in this case:
foreign import stdcall unsafe "winbase.h GetCurrentProcessId"
c_GetCurrentProcessId :: IO DWORD
if you are going to use win32 system calls, i recommend you to find
helpfiles from win32 sdk, they contain all those info. or you may use
msdn on the web and search there
Bulat mailto:Bulat.Ziganshin at gmail.com
More information about the Haskell-Cafe