libavcodec/mpegvideo_enc.c:1382: error: Null Dereference
  pointer `desc` last assigned on line 1381 could be null and is dereferenced at line 1382, column 22.

libavcodec/mpegvideo_enc.c:1374:1: start of procedure frame_end()
1372. }
1373. 
1374. static void frame_end(MpegEncContext *s)
      ^
1375. {
1376.     int i;

libavcodec/mpegvideo_enc.c:1378:9: Taking true branch
1376.     int i;
1377. 
1378.     if (s->unrestricted_mv &&
              ^
1379.         s->current_picture.reference &&
1380.         !s->intra_only) {

libavcodec/mpegvideo_enc.c:1379:9: Taking true branch
1377. 
1378.     if (s->unrestricted_mv &&
1379.         s->current_picture.reference &&
              ^
1380.         !s->intra_only) {
1381.         const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(s->avctx->pix_fmt);

libavcodec/mpegvideo_enc.c:1380:10: Taking true branch
1378.     if (s->unrestricted_mv &&
1379.         s->current_picture.reference &&
1380.         !s->intra_only) {
               ^
1381.         const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(s->avctx->pix_fmt);
1382.         int hshift = desc->log2_chroma_w;

libavcodec/mpegvideo_enc.c:1381:9: 
1379.         s->current_picture.reference &&
1380.         !s->intra_only) {
1381.         const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(s->avctx->pix_fmt);
              ^
1382.         int hshift = desc->log2_chroma_w;
1383.         int vshift = desc->log2_chroma_h;

libavutil/pixdesc.c:1574:1: start of procedure av_pix_fmt_desc_get()
  1572. }
  1573. 
  1574. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
        ^
  1575. {
  1576.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)

libavutil/pixdesc.c:1576:9: Taking false branch
  1574. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
  1575. {
  1576.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
                ^
  1577.         return NULL;
  1578.     return &av_pix_fmt_descriptors[pix_fmt];

libavutil/pixdesc.c:1576:24: Taking true branch
  1574. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
  1575. {
  1576.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
                               ^
  1577.         return NULL;
  1578.     return &av_pix_fmt_descriptors[pix_fmt];

libavutil/pixdesc.c:1577:9: 
  1575. {
  1576.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
  1577.         return NULL;
                ^
  1578.     return &av_pix_fmt_descriptors[pix_fmt];
  1579. }

libavutil/pixdesc.c:1579:1: return from a call to av_pix_fmt_desc_get
  1577.         return NULL;
  1578.     return &av_pix_fmt_descriptors[pix_fmt];
  1579. }
        ^
  1580. 
  1581. const AVPixFmtDescriptor *av_pix_fmt_desc_next(const AVPixFmtDescriptor *prev)

libavcodec/mpegvideo_enc.c:1382:9: 
1380.         !s->intra_only) {
1381.         const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(s->avctx->pix_fmt);
1382.         int hshift = desc->log2_chroma_w;
              ^
1383.         int vshift = desc->log2_chroma_h;
1384.         s->dsp.draw_edges(s->current_picture.f->data[0], s->linesize,
