From c22019dec5629967a092c1a64159469ad8fef5d4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Thomas=20M=C3=BCller?= <thomas.mueller@tmit.eu>
Date: Fri, 22 Nov 2013 12:20:06 +0100
Subject: [PATCH] Working on a chunked video can result in a broken frame index
 the option -vsync 1 can heal that

---
 lib/private/preview/movies.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/private/preview/movies.php b/lib/private/preview/movies.php
index 276209a876..3cbbaa9d3b 100644
--- a/lib/private/preview/movies.php
+++ b/lib/private/preview/movies.php
@@ -52,7 +52,7 @@ if (!\OC_Util::runningOnWindows()) {
 				if (self::$avconvBinary) {
 					$cmd = self::$avconvBinary . ' -an -y -ss 5'.
 						' -i ' . escapeshellarg($absPath) .
-						' -f mjpeg -vframes 1 ' . escapeshellarg($tmpPath) .
+						' -f mjpeg -vframes 1 -vsync 1 ' . escapeshellarg($tmpPath) .
 						' > /dev/null 2>&1';
 				}
 				else {
-- 
GitLab