mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-02-27 17:21:05 +00:00
avformat/rtsp: #if unused functions away, fix -O0 compilation
parse_rtsp_message() is only called if the rtsp demuxer is enabled and so it is normally compiled away if said demuxer is disabled. Yet this does not happen when compiling with -O0 and this leads to a linking failure because parse_rtsp_message() calls functions that may not be available if the rtsp demuxer is disabled. Fix this by properly #if'ing the unused functions away. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
a0d7e41ad7
commit
aeb5d943c6
@ -246,6 +246,7 @@ static void finalize_rtp_handler_init(AVFormatContext *s, RTSPStream *rtsp_st,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if CONFIG_RTSP_DEMUXER
|
||||||
static int init_satip_stream(AVFormatContext *s)
|
static int init_satip_stream(AVFormatContext *s)
|
||||||
{
|
{
|
||||||
RTSPState *rt = s->priv_data;
|
RTSPState *rt = s->priv_data;
|
||||||
@ -274,6 +275,7 @@ static int init_satip_stream(AVFormatContext *s)
|
|||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* parse the rtpmap description: <codec_name>/<clock_rate>[/<other params>] */
|
/* parse the rtpmap description: <codec_name>/<clock_rate>[/<other params>] */
|
||||||
static int sdp_parse_rtpmap(AVFormatContext *s,
|
static int sdp_parse_rtpmap(AVFormatContext *s,
|
||||||
@ -2006,6 +2008,7 @@ redirect:
|
|||||||
#endif /* CONFIG_RTSP_DEMUXER || CONFIG_RTSP_MUXER */
|
#endif /* CONFIG_RTSP_DEMUXER || CONFIG_RTSP_MUXER */
|
||||||
|
|
||||||
#if CONFIG_RTPDEC
|
#if CONFIG_RTPDEC
|
||||||
|
#if CONFIG_RTSP_DEMUXER
|
||||||
static int parse_rtsp_message(AVFormatContext *s)
|
static int parse_rtsp_message(AVFormatContext *s)
|
||||||
{
|
{
|
||||||
RTSPState *rt = s->priv_data;
|
RTSPState *rt = s->priv_data;
|
||||||
@ -2028,6 +2031,7 @@ static int parse_rtsp_message(AVFormatContext *s)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
static int udp_read_packet(AVFormatContext *s, RTSPStream **prtsp_st,
|
static int udp_read_packet(AVFormatContext *s, RTSPStream **prtsp_st,
|
||||||
uint8_t *buf, int buf_size, int64_t wait_end)
|
uint8_t *buf, int buf_size, int64_t wait_end)
|
||||||
|
Loading…
Reference in New Issue
Block a user