forked from FFmpeg/FFmpeg
add FF_API_REGISTER_PROTOCOL define to disable the deprecated
register_protocol() function Originally committed as revision 24840 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
b2125520e7
commit
838b27b42c
3 changed files with 6 additions and 3 deletions
|
@ -48,6 +48,9 @@
|
||||||
#ifndef FF_API_URL_CLASS
|
#ifndef FF_API_URL_CLASS
|
||||||
#define FF_API_URL_CLASS (LIBAVFORMAT_VERSION_MAJOR >= 53)
|
#define FF_API_URL_CLASS (LIBAVFORMAT_VERSION_MAJOR >= 53)
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef FF_API_REGISTER_PROTOCOL
|
||||||
|
#define FF_API_REGISTER_PROTOCOL (LIBAVFORMAT_VERSION_MAJOR < 53)
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* I return the LIBAVFORMAT_VERSION_INT constant. You got
|
* I return the LIBAVFORMAT_VERSION_INT constant. You got
|
||||||
|
|
|
@ -71,7 +71,7 @@ int av_register_protocol2(URLProtocol *protocol, int size)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if LIBAVFORMAT_VERSION_MAJOR < 53
|
#if FF_API_REGISTER_PROTOCOL
|
||||||
/* The layout of URLProtocol as of when major was bumped to 52 */
|
/* The layout of URLProtocol as of when major was bumped to 52 */
|
||||||
struct URLProtocol_compat {
|
struct URLProtocol_compat {
|
||||||
const char *name;
|
const char *name;
|
||||||
|
|
|
@ -256,7 +256,7 @@ typedef struct URLProtocol {
|
||||||
const AVClass *priv_data_class;
|
const AVClass *priv_data_class;
|
||||||
} URLProtocol;
|
} URLProtocol;
|
||||||
|
|
||||||
#if LIBAVFORMAT_VERSION_MAJOR < 53
|
#if FF_API_REGISTER_PROTOCOL
|
||||||
extern URLProtocol *first_protocol;
|
extern URLProtocol *first_protocol;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -269,7 +269,7 @@ extern URLInterruptCB *url_interrupt_cb;
|
||||||
*/
|
*/
|
||||||
URLProtocol *av_protocol_next(URLProtocol *p);
|
URLProtocol *av_protocol_next(URLProtocol *p);
|
||||||
|
|
||||||
#if LIBAVFORMAT_VERSION_MAJOR < 53
|
#if FF_API_REGISTER_PROTOCOL
|
||||||
/**
|
/**
|
||||||
* @deprecated Use av_register_protocol() instead.
|
* @deprecated Use av_register_protocol() instead.
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue