Skip to content

Commit

Permalink
Fixes of rather stupid mistakes :-)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluecube committed Dec 1, 2012
1 parent 985541a commit 8415b36
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions inhibit_shutdown.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ def check_services():
proto = items[0]
port = int(items[3].split(':')[-1])

if (proto, port) in accepted:
if (proto, port) in watched:
print("{}: Found {} connection from {} to port {}".format(service_name, proto, items[4], port))
return True

print("{} No connection found.".format(service_name))
return False

while not xbmc.abortRequested:
if check_services:
if check_services():
print("{}: Inhibiting idle shutdown".format(service_name))
xbmc.executebuiltin('InhibitIdleShutdown')
else:
Expand Down

0 comments on commit 8415b36

Please sign in to comment.