[pitivi] pipeline: Do not try to seek on empty timeline



commit adc18bab5d65f67812883300c9023b79ee854a05
Author: Thibault Saunier <tsaunier gnome org>
Date:   Sun Sep 27 19:56:19 2015 +0200

    pipeline: Do not try to seek on empty timeline
    
    That could lead to several different issues and is incorrect to do so.
    
    Fixes T3345

 pitivi/utils/pipeline.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/pitivi/utils/pipeline.py b/pitivi/utils/pipeline.py
index 56a9dc2..51a0b00 100644
--- a/pitivi/utils/pipeline.py
+++ b/pitivi/utils/pipeline.py
@@ -695,6 +695,9 @@ class Pipeline(GES.Pipeline, SimplePipeline):
         self.simple_seek(position)
 
     def simple_seek(self, position):
+        if self._timeline.is_empty():
+            return
+
         st = Gst.Structure.new_empty("seek")
 
         if self.getState() == Gst.State.PLAYING:


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