Commit d205c8f3 authored by James Almer's avatar James Almer

avcodec/avpacket: remove unnecessary check in av_packet_make_writable()

Zero sized packets are already handled below in the function.
This is more in line with av_packet_ref().
Signed-off-by: 's avatarJames Almer <jamrial@gmail.com>
parent 3914c8e0
......@@ -660,9 +660,6 @@ int av_packet_make_writable(AVPacket *pkt)
if (pkt->buf && av_buffer_is_writable(pkt->buf))
return 0;
if (!pkt->data)
return AVERROR(EINVAL);
ret = packet_alloc(&buf, pkt->size);
if (ret < 0)
return ret;
......
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