address the last remaining warning by Clang's static analyzer

Signed-off-by: Erik Boasson <eb@ilities.com>
This commit is contained in:
Erik Boasson 2019-01-21 17:36:33 +01:00
parent 274f7bfc95
commit e55dc3703a

View file

@ -1945,10 +1945,9 @@ nn_reorder_result_t nn_reorder_rsample (struct nn_rsample_chain *sc, struct nn_r
reorder->n_samples++; reorder->n_samples++;
} }
} }
else if (s->min == reorder->max_sampleiv->u.reorder.maxp1) else if (((void) assert (reorder->max_sampleiv != NULL)), (s->min == reorder->max_sampleiv->u.reorder.maxp1))
{ {
/* note: sampleivtree not empty <=> max_sampleiv is set (compilers /* (sampleivtree not empty) <=> (max_sampleiv is non-NULL), for which there is an assert at the beginning but compilers and static analyzers don't all quite get that ... the somewhat crazy assert shuts up Clang's static analyzer */
and static analyzers may warn) */
if (delivery_queue_full_p) if (delivery_queue_full_p)
{ {
/* growing last inteval will not be accepted when this flag is set */ /* growing last inteval will not be accepted when this flag is set */