splitmuxsink: Fix deadlock case when source reaches EOS
authorXavier Claessens <xavier.claessens@collabora.com>
Wed, 4 May 2016 15:15:20 +0000 (11:15 -0400)
committerJan Schmidt <jan@centricular.com>
Wed, 4 May 2016 15:22:10 +0000 (01:22 +1000)
https://bugzilla.gnome.org/show_bug.cgi?id=765072

gst/multifile/gstsplitmuxsink.c

index f3b4df1..4e8da80 100644 (file)
@@ -942,6 +942,11 @@ check_completed_gop (GstSplitMuxSink * splitmux, MqStreamCtx * ctx)
     }
   }
 
+  /* If upstream reached EOS we are not expecting more data, no need to wait
+   * here. */
+  if (ctx->in_eos)
+    return;
+
   /* Some pad is not yet ready, or GOP is being pushed
    * either way, sleep and wait to get woken */
   current_max_in_running_time = splitmux->max_in_running_time;