[FFmpeg-devel] [PATCH 35/50] avdevice/xcbgrab: stop using av_init_packet()

James Almer jamrial at gmail.com
Thu Feb 4 21:09:50 EET 2021


Signed-off-by: James Almer <jamrial at gmail.com>
---
 libavdevice/xcbgrab.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/libavdevice/xcbgrab.c b/libavdevice/xcbgrab.c
index 95bdc8ab9d..908e189b35 100644
--- a/libavdevice/xcbgrab.c
+++ b/libavdevice/xcbgrab.c
@@ -184,8 +184,6 @@ static int xcbgrab_frame(AVFormatContext *s, AVPacket *pkt)
     data   = xcb_get_image_data(img);
     length = xcb_get_image_data_length(img);
 
-    av_init_packet(pkt);
-
     pkt->buf = av_buffer_create(data, length, xcbgrab_image_reply_free, img, 0);
     if (!pkt->buf) {
         free(img);
@@ -301,8 +299,6 @@ static int xcbgrab_frame_shm(AVFormatContext *s, AVPacket *pkt)
 
     free(img);
 
-    av_init_packet(pkt);
-
     pkt->buf = buf;
     pkt->data = buf->data;
     pkt->size = c->frame_size;
-- 
2.30.0



More information about the ffmpeg-devel mailing list