aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/avpacket.c
diff options
context:
space:
mode:
authorJames Almer <jamrial@gmail.com>2021-03-05 11:26:24 -0300
committerJames Almer <jamrial@gmail.com>2021-03-17 14:12:17 -0300
commitd422b2ed87ee7d3b3014cd3fac553e6aad7d4f14 (patch)
tree06b1f9e88cfab2675afd529468f47ab851f1bab3 /libavcodec/avpacket.c
parentf7db77bd8785d1715d3e7ed7e69bd1cc991f2d07 (diff)
downloadffmpeg-d422b2ed87ee7d3b3014cd3fac553e6aad7d4f14.tar.gz
avcodec/packet_internal: make avpriv_packet_list_* functions use an internal struct
The next pointer is kept at the end for backwards compatability until the major bump, when it should ideally be moved at the front. Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/avpacket.c')
-rw-r--r--libavcodec/avpacket.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/libavcodec/avpacket.c b/libavcodec/avpacket.c
index 945ec2004b..6840688b15 100644
--- a/libavcodec/avpacket.c
+++ b/libavcodec/avpacket.c
@@ -737,13 +737,13 @@ FF_ENABLE_DEPRECATION_WARNINGS
#endif
}
-int avpriv_packet_list_put(AVPacketList **packet_buffer,
- AVPacketList **plast_pktl,
+int avpriv_packet_list_put(PacketList **packet_buffer,
+ PacketList **plast_pktl,
AVPacket *pkt,
int (*copy)(AVPacket *dst, const AVPacket *src),
int flags)
{
- AVPacketList *pktl = av_mallocz(sizeof(AVPacketList));
+ PacketList *pktl = av_mallocz(sizeof(PacketList));
int ret;
if (!pktl)
@@ -774,11 +774,11 @@ int avpriv_packet_list_put(AVPacketList **packet_buffer,
return 0;
}
-int avpriv_packet_list_get(AVPacketList **pkt_buffer,
- AVPacketList **pkt_buffer_end,
+int avpriv_packet_list_get(PacketList **pkt_buffer,
+ PacketList **pkt_buffer_end,
AVPacket *pkt)
{
- AVPacketList *pktl;
+ PacketList *pktl;
if (!*pkt_buffer)
return AVERROR(EAGAIN);
pktl = *pkt_buffer;
@@ -790,12 +790,12 @@ int avpriv_packet_list_get(AVPacketList **pkt_buffer,
return 0;
}
-void avpriv_packet_list_free(AVPacketList **pkt_buf, AVPacketList **pkt_buf_end)
+void avpriv_packet_list_free(PacketList **pkt_buf, PacketList **pkt_buf_end)
{
- AVPacketList *tmp = *pkt_buf;
+ PacketList *tmp = *pkt_buf;
while (tmp) {
- AVPacketList *pktl = tmp;
+ PacketList *pktl = tmp;
tmp = pktl->next;
av_packet_unref(&pktl->pkt);
av_freep(&pktl);