end18 / psutil

Automatically exported from code.google.com/p/psutil
Other
0 stars 0 forks source link

WindowsError can be raised on Windows for resume() and suspend() methods #145

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
>>> psutil.Process(0).resume()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "psutil\__init__.py", line 420, in resume
    self._platform_impl.resume_process()
  File "psutil\_psmswindows.py", line 198, in resume_process
    return _psutil_mswindows.resume_process(self.pid)
WindowsError: [Error 87] The parameter is incorrect
>>>
>>>
>>> psutil.Process(4).resume()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "psutil\__init__.py", line 420, in resume
    self._platform_impl.resume_process()
  File "psutil\_psmswindows.py", line 198, in resume_process
    return _psutil_mswindows.resume_process(self.pid)
WindowsError: [Error 5] Access is denied
>>>

What is the expected output? What do you see instead?
In both cases AccessDenied exception should be raised instead.

Original issue reported on code.google.com by g.rodola on 27 Dec 2010 at 6:21

GoogleCodeExporter commented 9 years ago
Fixed in r875.

Original comment by g.rodola on 27 Dec 2010 at 6:37

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Updated csets after the SVN -> Mercurial migration:
r875 == revision 6e1c7ed0bf5a

Original comment by g.rodola on 2 Mar 2013 at 11:57