[Swan-dev] puzzled by TS code Coverity flagged

D. Hugh Redelmeier hugh at mimosa.com
Wed Dec 21 10:26:06 EET 2022


Coverity flags an uninitialized scalar value in ikev2_ts.c.

The scalar in question is verify_rekey_child_request_ts()'s "best".

Part of best seems to be initialized by calls to fit_tsp_to_end
but only some paths through the function initialize.

The bool result returned does not actually indicate whether initialization 
happened, but the caller seems to act as if it does.

So: I think that Coverity is right: something is amiss.

Since I havent taken the time to understand the code, I could be wrong.


More information about the Swan-dev mailing list