[PATCH] Check for a GLib source ID of None in unwatchAllProcesses.

David Shea dshea at redhat.com
Thu Nov 13 20:41:15 UTC 2014


This check is in unwatchProcess but didn't make it to the other method.
The source ID will be None if the switch to GLib process watching done
by the GUI has not completed.
---
 pyanaconda/iutil.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/pyanaconda/iutil.py b/pyanaconda/iutil.py
index bcd5b55..5549e5a 100644
--- a/pyanaconda/iutil.py
+++ b/pyanaconda/iutil.py
@@ -541,7 +541,8 @@ def unwatchAllProcesses():
     """Clear the watched process list."""
     global _forever_pids
     for child_pid in _forever_pids:
-        GLib.source_remove(_forever_pids[child_pid][1])
+        if _forever_pids[child_pid][1]:
+            GLib.source_remove(_forever_pids[child_pid][1])
     _forever_pids = {}
 
 def getDirSize(directory):
-- 
2.1.0



More information about the anaconda-patches mailing list