Browse Source

win-dshow: Fix decoding issues from encoded devices

jp9000 7 years ago
parent
commit
bd30a0874d
1 changed files with 2 additions and 2 deletions
  1. 2 2
      plugins/win-dshow/ffmpeg-decode.c

+ 2 - 2
plugins/win-dshow/ffmpeg-decode.c

@@ -159,7 +159,7 @@ bool ffmpeg_decode_audio(struct ffmpeg_decode *decode,
 
 
 	if (ret < 0)
 	if (ret < 0)
 		return false;
 		return false;
-	else if (ret == 0 || !got_frame)
+	else if (!got_frame)
 		return true;
 		return true;
 
 
 	for (size_t i = 0; i < MAX_AV_PLANES; i++)
 	for (size_t i = 0; i < MAX_AV_PLANES; i++)
@@ -219,7 +219,7 @@ bool ffmpeg_decode_video(struct ffmpeg_decode *decode,
 
 
 	if (ret < 0)
 	if (ret < 0)
 		return false;
 		return false;
-	else if (ret == 0 || !got_frame)
+	else if (!got_frame)
 		return true;
 		return true;
 
 
 	for (size_t i = 0; i < MAX_AV_PLANES; i++) {
 	for (size_t i = 0; i < MAX_AV_PLANES; i++) {