Add some comments to make clear how the sleep assertion is released.

This commit is contained in:
Greg Neagle
2012-08-15 15:27:07 -07:00
parent 1a9ba0c027
commit 80cec70612
+4
View File
@@ -1085,6 +1085,10 @@ def run(only_unattended=False):
only_unattended: Boolean. If True, only do unattended_(un)install pkgs.
"""
sleepassertion = assertNoIdleSleep()
# we hold onto the launchd job object in order to keep
# pmset noidle running. When this object is destroyed the
# job is unloaded and removed.
managedinstallbase = munkicommon.pref('ManagedInstallDir')
installdir = os.path.join(managedinstallbase , 'Cache')