libavformat/oggparseflac.c:43: error: Null Dereference
  pointer `&gb->buffer` last assigned on line 42 could be null and is dereferenced by call to `skip_bits1()` at line 43, column 5.

libavformat/oggparseflac.c:29:1: start of procedure flac_header()
27. #define OGG_FLAC_METADATA_TYPE_STREAMINFO 0x7F
28. 
29. static int
    ^
30. flac_header (AVFormatContext * s, int idx)
31. {

libavformat/oggparseflac.c:32:5: 
30. flac_header (AVFormatContext * s, int idx)
31. {
32.     struct ogg *ogg = s->priv_data;
        ^
33.     struct ogg_stream *os = ogg->streams + idx;
34.     AVStream *st = s->streams[idx];

libavformat/oggparseflac.c:33:5: 
31. {
32.     struct ogg *ogg = s->priv_data;
33.     struct ogg_stream *os = ogg->streams + idx;
        ^
34.     AVStream *st = s->streams[idx];
35.     GetBitContext gb;

libavformat/oggparseflac.c:34:5: 
32.     struct ogg *ogg = s->priv_data;
33.     struct ogg_stream *os = ogg->streams + idx;
34.     AVStream *st = s->streams[idx];
        ^
35.     GetBitContext gb;
36.     FLACStreaminfo si;

libavformat/oggparseflac.c:39:9: Taking false branch
37.     int mdt;
38. 
39.     if (os->buf[os->pstart] == 0xff)
            ^
40.         return 0;
41. 

libavformat/oggparseflac.c:42:5: 
40.         return 0;
41. 
42.     init_get_bits(&gb, os->buf + os->pstart, os->psize*8);
        ^
43.     skip_bits1(&gb); /* metadata_last */
44.     mdt = get_bits(&gb, 7);

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

libavcodec/bitstream.h:740:5: 
  738.                    const uint8_t *buffer, int bit_size)
  739. {
  740.     int buffer_size= (bit_size+7)>>3;
           ^
  741.     if(buffer_size < 0 || bit_size < 0) {
  742.         buffer_size = bit_size = 0;

libavcodec/bitstream.h:741:8: Taking true branch
  739. {
  740.     int buffer_size= (bit_size+7)>>3;
  741.     if(buffer_size < 0 || bit_size < 0) {
              ^
  742.         buffer_size = bit_size = 0;
  743.         buffer = NULL;

libavcodec/bitstream.h:742:9: 
  740.     int buffer_size= (bit_size+7)>>3;
  741.     if(buffer_size < 0 || bit_size < 0) {
  742.         buffer_size = bit_size = 0;
               ^
  743.         buffer = NULL;
  744.     }

libavcodec/bitstream.h:743:9: 
  741.     if(buffer_size < 0 || bit_size < 0) {
  742.         buffer_size = bit_size = 0;
  743.         buffer = NULL;
               ^
  744.     }
  745. 

libavcodec/bitstream.h:746:5: 
  744.     }
  745. 
  746.     s->buffer= buffer;
           ^
  747.     s->size_in_bits= bit_size;
  748.     s->buffer_end= buffer + buffer_size;

libavcodec/bitstream.h:747:5: 
  745. 
  746.     s->buffer= buffer;
  747.     s->size_in_bits= bit_size;
           ^
  748.     s->buffer_end= buffer + buffer_size;
  749. #ifdef ALT_BITSTREAM_READER

libavcodec/bitstream.h:748:5: 
  746.     s->buffer= buffer;
  747.     s->size_in_bits= bit_size;
  748.     s->buffer_end= buffer + buffer_size;
           ^
  749. #ifdef ALT_BITSTREAM_READER
  750.     s->index=0;

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

libavcodec/bitstream.h:760:1: return from a call to init_get_bits
  758.     skip_bits_long(s, 0);
  759. #endif
  760. }
       ^
  761. 
  762. static inline void align_get_bits(GetBitContext *s)

libavformat/oggparseflac.c:43:5: 
41. 
42.     init_get_bits(&gb, os->buf + os->pstart, os->psize*8);
43.     skip_bits1(&gb); /* metadata_last */
        ^
44.     mdt = get_bits(&gb, 7);
45. 

libavcodec/bitstream.h:689:1: start of procedure skip_bits1()
  687. }
  688. 
  689. static inline void skip_bits1(GetBitContext *s){
       ^
  690.     skip_bits(s, 1);
  691. }

libavcodec/bitstream.h:690:5: 
  688. 
  689. static inline void skip_bits1(GetBitContext *s){
  690.     skip_bits(s, 1);
           ^
  691. }
  692. 

libavcodec/bitstream.h:657:1: start of procedure skip_bits()
    655. }
    656. 
    657. static inline void skip_bits(GetBitContext *s, int n){
         ^
    658.  //Note gcc seems to optimize this to s->index+=n for the ALT_READER :))
    659.     OPEN_READER(re, s)

libavcodec/bitstream.h:659:5: 
    657. static inline void skip_bits(GetBitContext *s, int n){
    658.  //Note gcc seems to optimize this to s->index+=n for the ALT_READER :))
    659.     OPEN_READER(re, s)
             ^
    660.     UPDATE_CACHE(re, s)
    661.     LAST_SKIP_BITS(re, s, n)

libavcodec/bitstream.h:660:5: 
    658.  //Note gcc seems to optimize this to s->index+=n for the ALT_READER :))
    659.     OPEN_READER(re, s)
    660.     UPDATE_CACHE(re, s)
             ^
    661.     LAST_SKIP_BITS(re, s, n)
    662.     CLOSE_READER(re, s)
