Coverity infers from the check of original->expect in the call to
fr_radius_decode_simple() that original->expect can be NULL, and
hence the later call to rs_stats_update_latency() call that
dereferences original->expect may fail. It may be that if original
and original->linked are non-NULL, one can infer original->expect
is non-NULL. Coverity can't; hence the added check on that call to
rs_stats_update_latency()..
* It also justifies allocating FR_RADIUS_CODE_MAXinstances of rs_latency_t.
*/
rs_stats_update_latency(&stats->exchange[packet->code], &latency);
- rs_stats_update_latency(&stats->exchange[original->expect->code], &latency);
+ if (original->expect) rs_stats_update_latency(&stats->exchange[original->expect->code], &latency);
/*
* We're filtering on response, now print out the full data from the request