libswscale/utils.c:803: error: Null Dereference
  pointer `desc` last assigned on line 802 could be null and is dereferenced at line 803, column 10.

libswscale/utils.c:800:1: start of procedure getSubSampleFactors()
798. #endif /* HAVE_MMXEXT_INLINE */
799. 
800. static void getSubSampleFactors(int *h, int *v, enum AVPixelFormat format)
     ^
801. {
802.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(format);

libswscale/utils.c:802:5: 
800. static void getSubSampleFactors(int *h, int *v, enum AVPixelFormat format)
801. {
802.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(format);
         ^
803.     *h = desc->log2_chroma_w;
804.     *v = desc->log2_chroma_h;

libavutil/pixdesc.c:1922:1: start of procedure av_pix_fmt_desc_get()
  1920. }
  1921. 
  1922. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
        ^
  1923. {
  1924.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)

libavutil/pixdesc.c:1924:9: Taking false branch
  1922. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
  1923. {
  1924.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
                ^
  1925.         return NULL;
  1926.     return &av_pix_fmt_descriptors[pix_fmt];

libavutil/pixdesc.c:1924:24: Taking true branch
  1922. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
  1923. {
  1924.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
                               ^
  1925.         return NULL;
  1926.     return &av_pix_fmt_descriptors[pix_fmt];

libavutil/pixdesc.c:1925:9: 
  1923. {
  1924.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
  1925.         return NULL;
                ^
  1926.     return &av_pix_fmt_descriptors[pix_fmt];
  1927. }

libavutil/pixdesc.c:1927:1: return from a call to av_pix_fmt_desc_get
  1925.         return NULL;
  1926.     return &av_pix_fmt_descriptors[pix_fmt];
  1927. }
        ^
  1928. 
  1929. const AVPixFmtDescriptor *av_pix_fmt_desc_next(const AVPixFmtDescriptor *prev)

libswscale/utils.c:803:5: 
801. {
802.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(format);
803.     *h = desc->log2_chroma_w;
         ^
804.     *v = desc->log2_chroma_h;
805. }

static void getSubSampleFactors(int *h, int *v, enum AVPixelFormat format)
{
    const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(format);
    *h = desc->log2_chroma_w;
    *v = desc->log2_chroma_h;
}
['static void getSubSampleFactors(int *h, int *v, enum AVPixelFormat format)\n{\n    const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(format);\n    *h = desc->log2_chroma_w;\n    *v = desc->log2_chroma_h;\n}', 'const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)\n{\n    if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)\n        return NULL;\n    return &av_pix_fmt_descriptors[pix_fmt];\n}']