aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorReinhard Tartler <siretart@tauware.de>2010-06-15 13:31:27 +0000
committerReinhard Tartler <siretart@tauware.de>2010-06-15 13:31:27 +0000
commit522f1861ca4dedc021fa515c79bc5bdc9685c250 (patch)
treee70ddf0c02a107e93a51a8df7e95587ef1bae1ae /libavformat
parent44f91788a5e39478509fc279445ff38fab770bc4 (diff)
downloadffmpeg-522f1861ca4dedc021fa515c79bc5bdc9685c250.tar.gz
Add compatibility wrappers for functions moved from lavf to lavc
When symbol versioning is enabled, moving symbols from one library to another breaks binary compatibility. This adds wrappers with the old version tag for the av_*packet functions recently moved to lavc. backport r23611 by mru Originally committed as revision 23613 to svn://svn.ffmpeg.org/ffmpeg/branches/0.6
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/utils.c32
1 files changed, 31 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index e975f5de24..6224a35d4d 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -282,8 +282,38 @@ AVInputFormat *av_find_input_format(const char *short_name)
return NULL;
}
-/* memory handling */
+#if LIBAVFORMAT_VERSION_MAJOR < 53 && CONFIG_SHARED && HAVE_SYMVER
+FF_SYMVER(void, av_destruct_packet_nofree, (AVPacket *pkt), "LIBAVFORMAT_52")
+{
+ av_destruct_packet_nofree(pkt);
+}
+
+FF_SYMVER(void, av_destruct_packet, (AVPacket *pkt), "LIBAVFORMAT_52")
+{
+ av_destruct_packet(pkt);
+}
+
+FF_SYMVER(int, av_new_packet, (AVPacket *pkt, int size), "LIBAVFORMAT_52")
+{
+ return av_new_packet(pkt, size);
+}
+
+FF_SYMVER(int, av_dup_packet, (AVPacket *pkt), "LIBAVFORMAT_52")
+{
+ return av_dup_packet(pkt);
+}
+
+FF_SYMVER(void, av_free_packet, (AVPacket *pkt), "LIBAVFORMAT_52")
+{
+ av_free_packet(pkt);
+}
+FF_SYMVER(void, av_init_packet, (AVPacket *pkt), "LIBAVFORMAT_52")
+{
+ av_log(NULL, AV_LOG_WARNING, "Diverting av_*_packet function calls to libavcodec. Recompile to improve performance\n");
+ av_init_packet(pkt);
+}
+#endif
int av_get_packet(ByteIOContext *s, AVPacket *pkt, int size)
{