libavfilter/vf_scale.c:167: error: Null Dereference
  pointer `desc` last assigned on line 151 could be null and is dereferenced at line 167, column 34.

libavfilter/vf_scale.c:146:1: start of procedure config_props()
144. }
145. 
146. static int config_props(AVFilterLink *outlink)
     ^
147. {
148.     AVFilterContext *ctx = outlink->src;

libavfilter/vf_scale.c:148:5: 
146. static int config_props(AVFilterLink *outlink)
147. {
148.     AVFilterContext *ctx = outlink->src;
         ^
149.     AVFilterLink *inlink = outlink->src->inputs[0];
150.     ScaleContext *scale = ctx->priv;

libavfilter/vf_scale.c:149:5: 
147. {
148.     AVFilterContext *ctx = outlink->src;
149.     AVFilterLink *inlink = outlink->src->inputs[0];
         ^
150.     ScaleContext *scale = ctx->priv;
151.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(inlink->format);

libavfilter/vf_scale.c:150:5: 
148.     AVFilterContext *ctx = outlink->src;
149.     AVFilterLink *inlink = outlink->src->inputs[0];
150.     ScaleContext *scale = ctx->priv;
         ^
151.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(inlink->format);
152.     int64_t w, h;

libavfilter/vf_scale.c:151:5: 
149.     AVFilterLink *inlink = outlink->src->inputs[0];
150.     ScaleContext *scale = ctx->priv;
151.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(inlink->format);
         ^
152.     int64_t w, h;
153.     double var_values[VARS_NB], res;

libavutil/pixdesc.c:1464:1: start of procedure av_pix_fmt_desc_get()
  1462. }
  1463. 
  1464. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
        ^
  1465. {
  1466.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)

libavutil/pixdesc.c:1466:9: Taking false branch
  1464. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
  1465. {
  1466.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
                ^
  1467.         return NULL;
  1468.     return &av_pix_fmt_descriptors[pix_fmt];

libavutil/pixdesc.c:1466:24: Taking true branch
  1464. const AVPixFmtDescriptor *av_pix_fmt_desc_get(enum AVPixelFormat pix_fmt)
  1465. {
  1466.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
                               ^
  1467.         return NULL;
  1468.     return &av_pix_fmt_descriptors[pix_fmt];

libavutil/pixdesc.c:1467:9: 
  1465. {
  1466.     if (pix_fmt < 0 || pix_fmt >= AV_PIX_FMT_NB)
  1467.         return NULL;
                ^
  1468.     return &av_pix_fmt_descriptors[pix_fmt];
  1469. }

libavutil/pixdesc.c:1469:1: return from a call to av_pix_fmt_desc_get
  1467.         return NULL;
  1468.     return &av_pix_fmt_descriptors[pix_fmt];
  1469. }
        ^
  1470. 
  1471. const AVPixFmtDescriptor *av_pix_fmt_desc_next(const AVPixFmtDescriptor *prev)

libavfilter/vf_scale.c:157:5: 
155.     int ret;
156. 
157.     var_values[VAR_PI]    = M_PI;
         ^
158.     var_values[VAR_PHI]   = M_PHI;
159.     var_values[VAR_E]     = M_E;

libavfilter/vf_scale.c:158:5: 
156. 
157.     var_values[VAR_PI]    = M_PI;
158.     var_values[VAR_PHI]   = M_PHI;
         ^
159.     var_values[VAR_E]     = M_E;
160.     var_values[VAR_IN_W]  = var_values[VAR_IW] = inlink->w;

libavfilter/vf_scale.c:159:5: 
157.     var_values[VAR_PI]    = M_PI;
158.     var_values[VAR_PHI]   = M_PHI;
159.     var_values[VAR_E]     = M_E;
         ^
160.     var_values[VAR_IN_W]  = var_values[VAR_IW] = inlink->w;
161.     var_values[VAR_IN_H]  = var_values[VAR_IH] = inlink->h;

libavfilter/vf_scale.c:160:5: 
158.     var_values[VAR_PHI]   = M_PHI;
159.     var_values[VAR_E]     = M_E;
160.     var_values[VAR_IN_W]  = var_values[VAR_IW] = inlink->w;
         ^
161.     var_values[VAR_IN_H]  = var_values[VAR_IH] = inlink->h;
162.     var_values[VAR_OUT_W] = var_values[VAR_OW] = NAN;

libavfilter/vf_scale.c:161:5: 
159.     var_values[VAR_E]     = M_E;
160.     var_values[VAR_IN_W]  = var_values[VAR_IW] = inlink->w;
161.     var_values[VAR_IN_H]  = var_values[VAR_IH] = inlink->h;
         ^
162.     var_values[VAR_OUT_W] = var_values[VAR_OW] = NAN;
163.     var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;

libavfilter/vf_scale.c:162:5: Skipping __builtin_nanf(): method has no implementation
160.     var_values[VAR_IN_W]  = var_values[VAR_IW] = inlink->w;
161.     var_values[VAR_IN_H]  = var_values[VAR_IH] = inlink->h;
162.     var_values[VAR_OUT_W] = var_values[VAR_OW] = NAN;
         ^
163.     var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;
164.     var_values[VAR_DAR]   = var_values[VAR_A]  = (double) inlink->w / inlink->h;

libavfilter/vf_scale.c:163:5: Skipping __builtin_nanf(): method has no implementation
161.     var_values[VAR_IN_H]  = var_values[VAR_IH] = inlink->h;
162.     var_values[VAR_OUT_W] = var_values[VAR_OW] = NAN;
163.     var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;
         ^
164.     var_values[VAR_DAR]   = var_values[VAR_A]  = (double) inlink->w / inlink->h;
165.     var_values[VAR_SAR]   = inlink->sample_aspect_ratio.num ?

libavfilter/vf_scale.c:164:5: 
162.     var_values[VAR_OUT_W] = var_values[VAR_OW] = NAN;
163.     var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;
164.     var_values[VAR_DAR]   = var_values[VAR_A]  = (double) inlink->w / inlink->h;
         ^
165.     var_values[VAR_SAR]   = inlink->sample_aspect_ratio.num ?
166.         (double) inlink->sample_aspect_ratio.num / inlink->sample_aspect_ratio.den : 1;

libavfilter/vf_scale.c:165:29: Condition is true
163.     var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;
164.     var_values[VAR_DAR]   = var_values[VAR_A]  = (double) inlink->w / inlink->h;
165.     var_values[VAR_SAR]   = inlink->sample_aspect_ratio.num ?
                                 ^
166.         (double) inlink->sample_aspect_ratio.num / inlink->sample_aspect_ratio.den : 1;
167.     var_values[VAR_HSUB]  = 1 << desc->log2_chroma_w;

libavfilter/vf_scale.c:165:5: 
163.     var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;
164.     var_values[VAR_DAR]   = var_values[VAR_A]  = (double) inlink->w / inlink->h;
165.     var_values[VAR_SAR]   = inlink->sample_aspect_ratio.num ?
         ^
166.         (double) inlink->sample_aspect_ratio.num / inlink->sample_aspect_ratio.den : 1;
167.     var_values[VAR_HSUB]  = 1 << desc->log2_chroma_w;

libavfilter/vf_scale.c:167:5: 
165.     var_values[VAR_SAR]   = inlink->sample_aspect_ratio.num ?
166.         (double) inlink->sample_aspect_ratio.num / inlink->sample_aspect_ratio.den : 1;
167.     var_values[VAR_HSUB]  = 1 << desc->log2_chroma_w;
         ^
168.     var_values[VAR_VSUB]  = 1 << desc->log2_chroma_h;
169. 
