libavformat/oggdec.c:194: error: Null Dereference
  pointer `nb` last assigned on line 190 could be null and is dereferenced by call to `memcpy()` at line 194, column 9.

libavformat/oggdec.c:187:1: start of procedure ogg_new_buf()
185. }
186. 
187. static int ogg_new_buf(struct ogg *ogg, int idx)
     ^
188. {
189.     struct ogg_stream *os = ogg->streams + idx;

libavformat/oggdec.c:189:5: 
187. static int ogg_new_buf(struct ogg *ogg, int idx)
188. {
189.     struct ogg_stream *os = ogg->streams + idx;
         ^
190.     uint8_t *nb = av_malloc(os->bufsize + FF_INPUT_BUFFER_PADDING_SIZE);
191.     int size = os->bufpos - os->pstart;

libavformat/oggdec.c:190:5: 
188. {
189.     struct ogg_stream *os = ogg->streams + idx;
190.     uint8_t *nb = av_malloc(os->bufsize + FF_INPUT_BUFFER_PADDING_SIZE);
         ^
191.     int size = os->bufpos - os->pstart;
192. 

libavutil/mem.c:61:1: start of procedure av_malloc()
  59.  * linker will do it automatically. */
  60. 
  61. void *av_malloc(size_t size)
      ^
  62. {
  63.     void *ptr = NULL;

libavutil/mem.c:63:5: 
  61. void *av_malloc(size_t size)
  62. {
  63.     void *ptr = NULL;
          ^
  64. #if CONFIG_MEMALIGN_HACK
  65.     long diff;

libavutil/mem.c:69:9: Taking true branch
  67. 
  68.     /* let's disallow possibly ambiguous cases */
  69.     if (size > (INT_MAX - 32) || !size)
              ^
  70.         return NULL;
  71. 

libavutil/mem.c:70:9: 
  68.     /* let's disallow possibly ambiguous cases */
  69.     if (size > (INT_MAX - 32) || !size)
  70.         return NULL;
              ^
  71. 
  72. #if CONFIG_MEMALIGN_HACK

libavutil/mem.c:114:1: return from a call to av_malloc
  112. #endif
  113.     return ptr;
  114. }
       ^
  115. 
  116. void *av_realloc(void *ptr, size_t size)

libavformat/oggdec.c:191:5: 
189.     struct ogg_stream *os = ogg->streams + idx;
190.     uint8_t *nb = av_malloc(os->bufsize + FF_INPUT_BUFFER_PADDING_SIZE);
191.     int size = os->bufpos - os->pstart;
         ^
192. 
193.     if (os->buf) {

libavformat/oggdec.c:193:9: Taking true branch
191.     int size = os->bufpos - os->pstart;
192. 
193.     if (os->buf) {
             ^
194.         memcpy(nb, os->buf + os->pstart, size);
195.         av_free(os->buf);

libavformat/oggdec.c:194:9: 
192. 
193.     if (os->buf) {
194.         memcpy(nb, os->buf + os->pstart, size);
             ^
195.         av_free(os->buf);
196.     }
