예제 #1
0
 def get_process_exe(self):
     exe = _convert_raw_path(_psutil_mswindows.get_process_exe(self.pid))
     # Note: if the folder containing the executable is changed
     # GetProcessImageFileName() returns the previous name, hence
     # this check. An empty string signals to try to guess the exe
     # from cmdline later.
     if not os.path.exists(exe):
         exe = ""
     return exe
예제 #2
0
 def get_process_exe(self):
     exe = _convert_raw_path(_psutil_mswindows.get_process_exe(self.pid))
     # Note: if the folder containing the executable is changed
     # GetProcessImageFileName() returns the previous name, hence
     # this check. An empty string signals to try to guess the exe
     # from cmdline later.
     if not os.path.exists(exe):
         exe = ""
     return exe
예제 #3
0
 def get_process_exe(self):
     # Note: os.path.exists(path) may return False even if the file
     # is there, see:
     # http://stackoverflow.com/questions/3112546/os-path-exists-lies
     return _convert_raw_path(_psutil_mswindows.get_process_exe(self.pid))