[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: [ANN] Winapi - a minimal but useful Windows API binding
- From: Lorenzo Donati <lorenzodonatibz@...>
- Date: Sun, 12 Jun 2011 14:57:30 +0200
On 12/06/2011 14.54, Lorenzo Donati wrote:
On 12/06/2011 13.18, KHMan wrote:
On 6/12/2011 5:52 PM, steve donovan wrote:
On Sun, Jun 12, 2011 at 11:06 AM, Lorenzo Donati wrote:
Add a method path() to return the actual process path in the file
don't know if this is easy to do (maybe not, since autoit doesn't
but it could be possible since Sysinternals' "ProcessExplorer" shows
Ah, I see what you mean: the existing get_process_name() method gives
the exe name but not the full path. I will investigate this further.
Are you sure?
From  it seems that GetModuleFileNameW is just the Unicode version
of GetModuleFileName. Excerpt from  (emphasis mine):
"Retrieves the fully-qualified path for the file that contains the
specified module. THE MODULE MUST HAVE BEEN LOADED BY THE CURRENT PROCESS."
The current process here is the lua interpreter running the script where
winapi's get_processes() is called. So this shouldn't be able to return
the path of an arbitrary process active on the system and whose pid is
returned by get_processes().
Am I missing something?
I pushed "send" a bit too early, sorry.
In the same page  above, the text continues saying:
"To locate the file for a module that was loaded by another process, use
the GetModuleFileNameEx function."
Is GetModuleFileNameEx which you meant?