libavformat/rtsp.c:696: error: Null Dereference
  pointer `st` last assigned on line 683 could be null and is dereferenced at line 696, column 56.

libavformat/rtsp.c:680:1: start of procedure rtsp_open_transport_ctx()
678. }
679. 
680. static int rtsp_open_transport_ctx(AVFormatContext *s, RTSPStream *rtsp_st)
     ^
681. {
682.     RTSPState *rt = s->priv_data;

libavformat/rtsp.c:682:5: 
680. static int rtsp_open_transport_ctx(AVFormatContext *s, RTSPStream *rtsp_st)
681. {
682.     RTSPState *rt = s->priv_data;
         ^
683.     AVStream *st = NULL;
684. 

libavformat/rtsp.c:683:5: 
681. {
682.     RTSPState *rt = s->priv_data;
683.     AVStream *st = NULL;
         ^
684. 
685.     /* open the RTP context */

libavformat/rtsp.c:686:9: Taking false branch
684. 
685.     /* open the RTP context */
686.     if (rtsp_st->stream_index >= 0)
             ^
687.         st = s->streams[rtsp_st->stream_index];
688.     if (!st)

libavformat/rtsp.c:688:10: Taking true branch
686.     if (rtsp_st->stream_index >= 0)
687.         st = s->streams[rtsp_st->stream_index];
688.     if (!st)
              ^
689.         s->ctx_flags |= AVFMTCTX_NOHEADER;
690. 

libavformat/rtsp.c:689:9: 
687.         st = s->streams[rtsp_st->stream_index];
688.     if (!st)
689.         s->ctx_flags |= AVFMTCTX_NOHEADER;
             ^
690. 
691.     if (s->oformat) {

libavformat/rtsp.c:691:9: Taking false branch
689.         s->ctx_flags |= AVFMTCTX_NOHEADER;
690. 
691.     if (s->oformat) {
             ^
692.         rtsp_st->transport_priv = rtsp_rtp_mux_open(s, st, rtsp_st->rtp_handle);
693.         /* Ownership of rtp_handle is passed to the rtp mux context */

libavformat/rtsp.c:695:16: Taking true branch
693.         /* Ownership of rtp_handle is passed to the rtp mux context */
694.         rtsp_st->rtp_handle = NULL;
695.     } else if (rt->transport == RTSP_TRANSPORT_RDT)
                    ^
696.         rtsp_st->transport_priv = ff_rdt_parse_open(s, st->index,
697.                                             rtsp_st->dynamic_protocol_context,

libavformat/rtsp.c:696:9: 
694.         rtsp_st->rtp_handle = NULL;
695.     } else if (rt->transport == RTSP_TRANSPORT_RDT)
696.         rtsp_st->transport_priv = ff_rdt_parse_open(s, st->index,
             ^
697.                                             rtsp_st->dynamic_protocol_context,
698.                                             rtsp_st->dynamic_handler);
