Skip to contentSkip to conversation

bitbake/process.py: Ensure queued UI events are queued right before we add our own handler

PATCH New Richard Purdie 1 participant 1 message Jul 6, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 bitbake/process.py: Ensure queued UI events are queued right before we add our own handler

(quoted diff) +0 -0

b/bitbake/lib/bb/server/process.py
index 3a0706c..ba91336 100644

bitbake/lib/bb/server/process.py +2 -3
@@ -83,15 +83,14 @@ class ProcessServer(Process):
         self.keep_running = Event()
         self.keep_running.set()
 
-        for event in bb.event.ui_queue:
-            self.event_queue.put(event)
-
     def register_idle_function(self, function, data):
         """Register a function to be called while the server is idle"""
         assert hasattr(function, '__call__')
         self._idlefunctions[function] = data
 
     def run(self):
+        for event in bb.event.ui_queue:
+            self.event_queue.put(event)
         self.event_handle = bb.event.register_UIHhandler(self)
         bb.cooker.server_main(self.cooker, self.main)