From 917fa192c72e226ffaddefbe6661ec3c405156cf Mon Sep 17 00:00:00 2001
From: Michael McConnell <soruk@eridani.co.uk>
Date: Wed, 7 Feb 2007 00:52:35 +0000
Subject: [PATCH] Fix to loss of sync in ffplay when paused patch by (Michael
 McConnell /// soruk put at here eridani and here a dot co.uk)

Originally committed as revision 7866 to svn://svn.ffmpeg.org/ffmpeg/trunk
---
 ffplay.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/ffplay.c b/ffplay.c
index 1c3aa63e897..2504878bd4f 100644
--- a/ffplay.c
+++ b/ffplay.c
@@ -984,8 +984,9 @@ static void stream_seek(VideoState *is, int64_t pos, int rel)
 static void stream_pause(VideoState *is)
 {
     is->paused = !is->paused;
-    if (is->paused) {
+    if (!is->paused) {
         is->video_current_pts = get_video_clock(is);
+        is->frame_timer += (av_gettime() - is->video_current_pts_time) / 1000000.0;
     }
 }
 
-- 
GitLab