libavformat/rdt.c:269: error: Null Dereference
  pointer `&gb->buffer` last assigned on line 268 could be null and is dereferenced by call to `get_bits1()` at line 269, column 21.

libavformat/rdt.c:193:1: start of procedure ff_rdt_parse_header()
191.  */
192. 
193. int
     ^
194. ff_rdt_parse_header(const uint8_t *buf, int len,
195.                     int *pset_id, int *pseq_no, int *pstream_id,

libavformat/rdt.c:199:5: 
197. {
198.     GetBitContext gb;
199.     int consumed = 0, set_id, seq_no, stream_id, is_keyframe,
         ^
200.         len_included, need_reliable;
201.     uint32_t timestamp;

libavformat/rdt.c:204:12: Loop condition is true. Entering loop body
202. 
203.     /* skip status packets */
204.     while (len >= 5 && buf[1] == 0xFF /* status packet */) {
                ^
205.         int pkt_len;
206. 

libavformat/rdt.c:204:24: Loop condition is true. Entering loop body
202. 
203.     /* skip status packets */
204.     while (len >= 5 && buf[1] == 0xFF /* status packet */) {
                            ^
205.         int pkt_len;
206. 

libavformat/rdt.c:207:15: Taking false branch
205.         int pkt_len;
206. 
207.         if (!(buf[0] & 0x80))
                   ^
208.             return -1; /* not followed by a data packet */
209. 

libavformat/rdt.c:210:9: 
208.             return -1; /* not followed by a data packet */
209. 
210.         pkt_len = AV_RB16(buf+3);
             ^
211.         buf += pkt_len;
212.         len -= pkt_len;

libavformat/rdt.c:211:9: 
209. 
210.         pkt_len = AV_RB16(buf+3);
211.         buf += pkt_len;
             ^
212.         len -= pkt_len;
213.         consumed += pkt_len;

libavformat/rdt.c:212:9: 
210.         pkt_len = AV_RB16(buf+3);
211.         buf += pkt_len;
212.         len -= pkt_len;
             ^
213.         consumed += pkt_len;
214.     }

libavformat/rdt.c:213:9: 
211.         buf += pkt_len;
212.         len -= pkt_len;
213.         consumed += pkt_len;
             ^
214.     }
215.     if (len < 16)

libavformat/rdt.c:204:12: Loop condition is true. Entering loop body
202. 
203.     /* skip status packets */
204.     while (len >= 5 && buf[1] == 0xFF /* status packet */) {
                ^
205.         int pkt_len;
206. 

libavformat/rdt.c:204:24: Loop condition is true. Entering loop body
202. 
203.     /* skip status packets */
204.     while (len >= 5 && buf[1] == 0xFF /* status packet */) {
                            ^
205.         int pkt_len;
206. 

libavformat/rdt.c:207:15: Taking false branch
205.         int pkt_len;
206. 
207.         if (!(buf[0] & 0x80))
                   ^
208.             return -1; /* not followed by a data packet */
209. 

libavformat/rdt.c:210:9: 
208.             return -1; /* not followed by a data packet */
209. 
210.         pkt_len = AV_RB16(buf+3);
             ^
211.         buf += pkt_len;
212.         len -= pkt_len;

libavformat/rdt.c:211:9: 
209. 
210.         pkt_len = AV_RB16(buf+3);
211.         buf += pkt_len;
             ^
212.         len -= pkt_len;
213.         consumed += pkt_len;

libavformat/rdt.c:212:9: 
210.         pkt_len = AV_RB16(buf+3);
211.         buf += pkt_len;
212.         len -= pkt_len;
             ^
213.         consumed += pkt_len;
214.     }

libavformat/rdt.c:213:9: 
211.         buf += pkt_len;
212.         len -= pkt_len;
213.         consumed += pkt_len;
             ^
214.     }
215.     if (len < 16)

libavformat/rdt.c:204:12: Loop condition is true. Entering loop body
202. 
203.     /* skip status packets */
204.     while (len >= 5 && buf[1] == 0xFF /* status packet */) {
                ^
205.         int pkt_len;
206. 

libavformat/rdt.c:204:24: Loop condition is false. Leaving loop
202. 
203.     /* skip status packets */
204.     while (len >= 5 && buf[1] == 0xFF /* status packet */) {
                            ^
205.         int pkt_len;
206. 

libavformat/rdt.c:215:9: Taking false branch
213.         consumed += pkt_len;
214.     }
215.     if (len < 16)
             ^
216.         return -1;
217.     /**

libavformat/rdt.c:268:5: 
266.      *     http://anonsvn.wireshark.org/viewvc/trunk/epan/dissectors/packet-rdt.c
267.      */
268.     init_get_bits(&gb, buf, len << 3);
         ^
269.     len_included  = get_bits1(&gb);
270.     need_reliable = get_bits1(&gb);

libavcodec/bitstream.h:741:1: start of procedure init_get_bits()
  739.  * @param bit_size the size of the buffer in bits
  740.  */
  741. static inline void init_get_bits(GetBitContext *s,
       ^
  742.                    const uint8_t *buffer, int bit_size)
  743. {

libavcodec/bitstream.h:744:5: 
  742.                    const uint8_t *buffer, int bit_size)
  743. {
  744.     int buffer_size= (bit_size+7)>>3;
           ^
  745.     if(buffer_size < 0 || bit_size < 0) {
  746.         buffer_size = bit_size = 0;

libavcodec/bitstream.h:745:8: Taking true branch
  743. {
  744.     int buffer_size= (bit_size+7)>>3;
  745.     if(buffer_size < 0 || bit_size < 0) {
              ^
  746.         buffer_size = bit_size = 0;
  747.         buffer = NULL;

libavcodec/bitstream.h:746:9: 
  744.     int buffer_size= (bit_size+7)>>3;
  745.     if(buffer_size < 0 || bit_size < 0) {
  746.         buffer_size = bit_size = 0;
               ^
  747.         buffer = NULL;
  748.     }

libavcodec/bitstream.h:747:9: 
  745.     if(buffer_size < 0 || bit_size < 0) {
  746.         buffer_size = bit_size = 0;
  747.         buffer = NULL;
               ^
  748.     }
  749. 

libavcodec/bitstream.h:750:5: 
  748.     }
  749. 
  750.     s->buffer= buffer;
           ^
  751.     s->size_in_bits= bit_size;
  752.     s->buffer_end= buffer + buffer_size;

libavcodec/bitstream.h:751:5: 
  749. 
  750.     s->buffer= buffer;
  751.     s->size_in_bits= bit_size;
           ^
  752.     s->buffer_end= buffer + buffer_size;
  753. #ifdef ALT_BITSTREAM_READER

libavcodec/bitstream.h:752:5: 
  750.     s->buffer= buffer;
  751.     s->size_in_bits= bit_size;
  752.     s->buffer_end= buffer + buffer_size;
           ^
  753. #ifdef ALT_BITSTREAM_READER
  754.     s->index=0;

libavcodec/bitstream.h:754:5: 
  752.     s->buffer_end= buffer + buffer_size;
  753. #ifdef ALT_BITSTREAM_READER
  754.     s->index=0;
           ^
  755. #elif defined LIBMPEG2_BITSTREAM_READER
  756.     s->buffer_ptr = (uint8_t*)((intptr_t)buffer&(~1));

libavcodec/bitstream.h:764:1: return from a call to init_get_bits
  762.     skip_bits_long(s, 0);
  763. #endif
  764. }
       ^
  765. 
  766. static inline void align_get_bits(GetBitContext *s)

libavformat/rdt.c:269:5: 
267.      */
268.     init_get_bits(&gb, buf, len << 3);
269.     len_included  = get_bits1(&gb);
         ^
270.     need_reliable = get_bits1(&gb);
271.     set_id        = get_bits(&gb, 5);

libavcodec/bitstream.h:669:1: start of procedure get_bits1()
  667. }
  668. 
  669. static inline unsigned int get_bits1(GetBitContext *s){
       ^
  670. #ifdef ALT_BITSTREAM_READER
  671.     int index= s->index;

libavcodec/bitstream.h:671:5: 
  669. static inline unsigned int get_bits1(GetBitContext *s){
  670. #ifdef ALT_BITSTREAM_READER
  671.     int index= s->index;
           ^
  672.     uint8_t result= s->buffer[ index>>3 ];
  673. #ifdef ALT_BITSTREAM_READER_LE

libavcodec/bitstream.h:672:5: 
  670. #ifdef ALT_BITSTREAM_READER
  671.     int index= s->index;
  672.     uint8_t result= s->buffer[ index>>3 ];
           ^
  673. #ifdef ALT_BITSTREAM_READER_LE
  674.     result>>= (index&0x07);
