skupperproject / skupper-router

An application-layer router for Skupper networks
https://skupper.io
Apache License 2.0
14 stars 18 forks source link

Coverity issue: http2 adaptor has to deal with return values of functions called from hash.c #1526

Closed ganeshmurthy closed 2 months ago

ganeshmurthy commented 3 months ago

Coverity error -

 CID 462712: (#1 of 1): Unchecked return value (CHECKED_RETURN)
3. check_return: Calling qd_hash_remove_str without checking return value (as is done elsewhere 4 out of 5 times)
61     {
62         assert(stream_id != 0);
63         qd_hash_t  *stream_id_hash = transport_handle->http2.stream_id_hash;
64         // Convert stream_id to string
65         char stream_id_str[11];
66         snprintf(stream_id_str, sizeof stream_id_str, "%" PRIu32, stream_id);
>>>     CID 462712:  Error handling issues  (CHECKED_RETURN)
>>>     Calling "qd_hash_remove_str" without checking return value (as is done elsewhere 4 out of 5 times).
67         qd_hash_remove_str(stream_id_hash, (const unsigned char *)stream_id_str);
68     }
69     
70     /*
71      * HTTP2 decoder callbacks
72      */