Skip to content
Snippets Groups Projects
Commit 25bd671e authored by Christophe Simonis's avatar Christophe Simonis
Browse files

[FIX] osutils: correct nt service check

bzr revid: chs@openerp.com-20121130103503-9l3elc3o1dgkovhe
parent 4622172c
Branches
Tags
No related merge requests found
......@@ -114,7 +114,7 @@ else:
with close_srv(ws.OpenSCManager(None, None, ws.SC_MANAGER_ALL_ACCESS)) as hscm:
with close_srv(wsu.SmartOpenService(hscm, nt_service_name, ws.SERVICE_ALL_ACCESS)) as hs:
info = ws.QueryServiceStatusEx(hs)
return info.ProcessId == getppid()
return info['ProcessId'] == getppid()
if __name__ == '__main__':
from pprint import pprint as pp
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment