[FFmpeg-cvslog] lavd/kmsgrab: Fix packet flag setting

Mark Thompson git at videolan.org
Thu Sep 14 11:26:40 EEST 2017


ffmpeg | branch: master | Mark Thompson <sw at jkqxz.net> | Thu Sep 14 09:14:36 2017 +0100| [16b44d9ab9fd81e4dfc5631a5fbc081b564f1037] | committer: Mark Thompson

lavd/kmsgrab: Fix packet flag setting

Found-by: James Almer <jamrial at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=16b44d9ab9fd81e4dfc5631a5fbc081b564f1037
---

 libavdevice/kmsgrab.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libavdevice/kmsgrab.c b/libavdevice/kmsgrab.c
index d0b9cf5001..d222abfd60 100644
--- a/libavdevice/kmsgrab.c
+++ b/libavdevice/kmsgrab.c
@@ -190,10 +190,10 @@ static int kmsgrab_read_packet(AVFormatContext *avctx, AVPacket *pkt)
     if (!pkt->buf)
         return AVERROR(ENOMEM);
 
-    pkt->data  = (uint8_t*)frame;
-    pkt->size  = sizeof(*frame);
-    pkt->pts   = now;
-    pkt->flags = AV_PKT_FLAG_TRUSTED;
+    pkt->data   = (uint8_t*)frame;
+    pkt->size   = sizeof(*frame);
+    pkt->pts    = now;
+    pkt->flags |= AV_PKT_FLAG_TRUSTED;
 
     return 0;
 }



More information about the ffmpeg-cvslog mailing list