[pitivi: 4/28] Relax the Pipeline.releaseQueueForFactoryStream checks to not raise an exception if there is no queu



commit f385ac9a510d0eb81e8d81907563b1ca4a3446a4
Author: Alex BÄluÈ <alexandru balut gmail com>
Date:   Wed Jul 6 15:01:48 2011 +0200

    Relax the Pipeline.releaseQueueForFactoryStream checks to not raise an exception if there is no queue

 pitivi/pipeline.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/pitivi/pipeline.py b/pitivi/pipeline.py
index 6c64ca5..975c163 100644
--- a/pitivi/pipeline.py
+++ b/pitivi/pipeline.py
@@ -781,7 +781,8 @@ class Pipeline(Signallable, Loggable):
 
         stream_entry = self._getStreamEntryForFactoryStream(factory, stream)
         if stream_entry.queue is None:
-            raise PipelineError("Couldn't find Queue for Stream/Factory")
+            # It can happen for example when the queue has not yet been created.
+            return
 
         stream_entry.queue_use_count -= 1
         if stream_entry.queue_use_count == 0:



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]