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

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

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

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

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

libavfilter/vf_scale.c:153:5: 
151.     AVFilterLink *inlink = outlink->src->inputs[0];
152.     ScaleContext *scale = ctx->priv;
153.     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(inlink->format);
         ^
154.     int64_t w, h;
155.     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:159:5: 
157.     int ret;
158. 
159.     var_values[VAR_PI]    = M_PI;
         ^
160.     var_values[VAR_PHI]   = M_PHI;
161.     var_values[VAR_E]     = M_E;

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

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

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

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

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

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

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

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

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

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