libavcodec/flacenc.c:533: error: Null Dereference
  pointer `udata` last assigned on line 531 could be null and is dereferenced at line 533, column 9.

libavcodec/flacenc.c:517:1: start of procedure calc_rice_params()
515. }
516. 
517. static uint32_t calc_rice_params(RiceContext *rc, int pmin, int pmax,
     ^
518.                                  int32_t *data, int n, int pred_order)
519. {

libavcodec/flacenc.c:527:5: 
525.     uint32_t sums[MAX_PARTITION_ORDER+1][MAX_PARTITIONS];
526. 
527.     assert(pmin >= 0 && pmin <= MAX_PARTITION_ORDER);
         ^
528.     assert(pmax >= 0 && pmax <= MAX_PARTITION_ORDER);
529.     assert(pmin <= pmax);

libavcodec/flacenc.c:528:5: 
526. 
527.     assert(pmin >= 0 && pmin <= MAX_PARTITION_ORDER);
528.     assert(pmax >= 0 && pmax <= MAX_PARTITION_ORDER);
         ^
529.     assert(pmin <= pmax);
530. 

libavcodec/flacenc.c:529:5: 
527.     assert(pmin >= 0 && pmin <= MAX_PARTITION_ORDER);
528.     assert(pmax >= 0 && pmax <= MAX_PARTITION_ORDER);
529.     assert(pmin <= pmax);
         ^
530. 
531.     udata = av_malloc(n * sizeof(uint32_t));

libavcodec/flacenc.c:531:5: 
529.     assert(pmin <= pmax);
530. 
531.     udata = av_malloc(n * sizeof(uint32_t));
         ^
532.     for(i=0; i<n; i++) {
533.         udata[i] = (2*data[i]) ^ (data[i]>>31);

libavutil/mem.c:42:1: start of procedure av_malloc()
  40.    linker will do it automatically */
  41. 
  42. void *av_malloc(unsigned int size)
      ^
  43. {
  44.     void *ptr;

libavutil/mem.c:50:8: Taking true branch
  48. 
  49.     /* let's disallow possible ambiguous cases */
  50.     if(size > (INT_MAX-16) )
             ^
  51.         return NULL;
  52. 

libavutil/mem.c:51:9: 
  49.     /* let's disallow possible ambiguous cases */
  50.     if(size > (INT_MAX-16) )
  51.         return NULL;
              ^
  52. 
  53. #ifdef CONFIG_MEMALIGN_HACK

libavutil/mem.c:92:1: return from a call to av_malloc
  90. #endif
  91.     return ptr;
  92. }
      ^
  93. 
  94. void *av_realloc(void *ptr, unsigned int size)

libavcodec/flacenc.c:532:9: 
530. 
531.     udata = av_malloc(n * sizeof(uint32_t));
532.     for(i=0; i<n; i++) {
             ^
533.         udata[i] = (2*data[i]) ^ (data[i]>>31);
534.     }

libavcodec/flacenc.c:532:14: Loop condition is true. Entering loop body
530. 
531.     udata = av_malloc(n * sizeof(uint32_t));
532.     for(i=0; i<n; i++) {
                  ^
533.         udata[i] = (2*data[i]) ^ (data[i]>>31);
534.     }

libavcodec/flacenc.c:533:9: 
531.     udata = av_malloc(n * sizeof(uint32_t));
532.     for(i=0; i<n; i++) {
533.         udata[i] = (2*data[i]) ^ (data[i]>>31);
             ^
534.     }
535. 
