Commit 54cb30ce authored by James Almer's avatar James Almer

avdevice/xcbgrab: stop using av_init_packet()

Signed-off-by: 's avatarJames Almer <jamrial@gmail.com>
parent 6b3a563b
......@@ -186,8 +186,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);
......@@ -303,8 +301,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;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment