mod_http2-2.0.27-1.fc41

List of Defects

Error: GCC_ANALYZER_WARNING (CWE-476): [#def1]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_bucket_beam.c: scope_hint: In function 'h2_beam_create'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_bucket_beam.c:313:18: warning[-Wanalyzer-null-dereference]: dereference of NULL '0'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_bucket_beam.c:31: included_from: Included from here.
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_bucket_beam.c:306:31: note: in expansion of macro 'h2_conn_ctx_get'
/usr/include/apr-1/apr_atomic.h:26: included_from: Included from here.
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_bucket_beam.c:18: included_from: Included from here.
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_bucket_beam.c:309:12: note: in expansion of macro 'apr_pcalloc'
#  311|       beam->from = from;
#  312|       beam->id = id;
#  313|->     beam->name = apr_psprintf(pool, "%s-%d-%s",
#  314|                                 conn_ctx->id, id, tag);
#  315|   

Error: CLANG_WARNING: [#def2]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c1.c:65:9: warning[deadcode.DeadStores]: Value stored to 'status' is never read
#   63|           /* some MPMs do not implemnent this */
#   64|           async_mpm = 0;
#   65|->         status = APR_SUCCESS;
#   66|       }
#   67|   

Error: GCC_ANALYZER_WARNING (CWE-476): [#def3]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c: scope_hint: In function 'h2_c2_abort'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:163:11: warning[-Wanalyzer-null-dereference]: dereference of NULL 'c2'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:159:31: note: in expansion of macro 'h2_conn_ctx_get'
#  161|       AP_DEBUG_ASSERT(conn_ctx);
#  162|       AP_DEBUG_ASSERT(conn_ctx->stream_id);
#  163|->     if(!c2->aborted && conn_ctx->bytes_sent) {
#  164|         h2_c2_log_io(c2, conn_ctx->bytes_sent);
#  165|       }

Error: GCC_ANALYZER_WARNING (CWE-476): [#def4]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:163:32: warning[-Wanalyzer-null-dereference]: dereference of NULL '0'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:370:31: note: in expansion of macro 'h2_conn_ctx_get'
/usr/include/httpd/http_config.h:551:17: note: in definition of macro 'ap_get_module_config'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:370:31: note: in expansion of macro 'h2_conn_ctx_get'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:23: included_from: Included from here.
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:373:5: note: in expansion of macro 'ap_assert'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:159:31: note: in expansion of macro 'h2_conn_ctx_get'
#  161|       AP_DEBUG_ASSERT(conn_ctx);
#  162|       AP_DEBUG_ASSERT(conn_ctx->stream_id);
#  163|->     if(!c2->aborted && conn_ctx->bytes_sent) {
#  164|         h2_c2_log_io(c2, conn_ctx->bytes_sent);
#  165|       }

Error: GCC_ANALYZER_WARNING (CWE-476): [#def5]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:167:17: warning[-Wanalyzer-null-dereference]: dereference of NULL '0'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:370:31: note: in expansion of macro 'h2_conn_ctx_get'
/usr/include/httpd/http_config.h:551:17: note: in definition of macro 'ap_get_module_config'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:370:31: note: in expansion of macro 'h2_conn_ctx_get'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:373:5: note: in expansion of macro 'ap_assert'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:159:31: note: in expansion of macro 'h2_conn_ctx_get'
#  165|       }
#  166|   
#  167|->     if (conn_ctx->beam_in) {
#  168|           h2_beam_abort(conn_ctx->beam_in, from);
#  169|       }

Error: GCC_ANALYZER_WARNING (CWE-476): [#def6]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c: scope_hint: In function 'h2_c2_filter_in'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:199:35: warning[-Wanalyzer-null-dereference]: dereference of NULL '*f.c'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:195:16: note: in expansion of macro 'h2_conn_ctx_get'
#  197|   
#  198|       if (mode == AP_MODE_INIT) {
#  199|->         return ap_get_brigade(f->c->input_filters, bb, mode, block, readbytes);
#  200|       }
#  201|       

Error: GCC_ANALYZER_WARNING (CWE-476): [#def7]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:202:13: warning[-Wanalyzer-null-dereference]: dereference of NULL '*f.c'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2.c:195:16: note: in expansion of macro 'h2_conn_ctx_get'
#  200|       }
#  201|       
#  202|->     if (f->c->aborted) {
#  203|           return APR_ECONNABORTED;
#  204|       }

Error: GCC_ANALYZER_WARNING (CWE-476): [#def8]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c: scope_hint: In function 'create_response'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c:310:16: warning[-Wanalyzer-null-dereference]: dereference of NULL '*r.content_languages'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c:35: included_from: Included from here.
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c:683:31: note: in expansion of macro 'h2_conn_ctx_get'
/usr/include/httpd/ap_expr.h:30: included_from: Included from here.
/usr/include/httpd/http_core.h:33: included_from: Included from here.
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c:25: included_from: Included from here.
/usr/include/httpd/http_config.h:551:17: note: in definition of macro 'ap_get_module_config'
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c:683:31: note: in expansion of macro 'h2_conn_ctx_get'
#  308|           int i;
#  309|           char *token;
#  310|->         char **languages = (char **)(r->content_languages->elts);
#  311|           const char *field = apr_table_get(r->headers_out, "Content-Language");
#  312|   

Error: CLANG_WARNING: [#def9]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_c2_filter.c:869:25: warning[deadcode.DeadStores]: Value stored to 'status' is never read
#  867|                       tmp = apr_brigade_split_ex(fctx->bbchunk, b, NULL);
#  868|                       if (!apr_is_empty_table(headers->headers)) {
#  869|->                         status = apr_brigade_puts(fctx->bbchunk, NULL, NULL, "0\r\n");
#  870|                           apr_table_do(ser_header, fctx->bbchunk, headers->headers, NULL);
#  871|                           status = apr_brigade_puts(fctx->bbchunk, NULL, NULL, "\r\n");

Error: CLANG_WARNING: [#def10]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_mplx.c:999:59: warning[core.NullDereference]: Access to field 'session' results in a dereference of a null pointer (loaded from variable 'stream')
#  997|               if (stream == APR_ARRAY_IDX(m->spurge, i, h2_stream*)) {
#  998|                   ap_log_cerror(APLOG_MARK, APLOG_WARNING, 0, c2,
#  999|->                               H2_STRM_LOG(APLOGNO(03517), stream, "already in spurge"));
# 1000|                   ap_assert("stream should not be in spurge" == NULL);
# 1001|                   return;

Error: CLANG_WARNING: [#def11]
mod_http2-2.0.27-build/mod_http2-2.0.27/mod_http2/h2_stream.c:1508:13: warning[deadcode.DeadStores]: Value stored to 'rv' is never read
# 1506|                             (long)length, (long)buf_len);
# 1507|               eos = 1;
# 1508|->             rv = APR_SUCCESS;
# 1509|           }
# 1510|           else if (APR_ECONNRESET == rv || APR_ECONNABORTED == rv) {

Scan Properties

analyzer-version-clang18.1.7
analyzer-version-cppcheck2.14.2
analyzer-version-gcc14.1.1
analyzer-version-gcc-analyzer14.1.1
analyzer-version-shellcheck0.10.0
enabled-pluginsclang, cppcheck, gcc, shellcheck
exit-code0
hostip-172-16-1-18.us-west-2.compute.internal
mock-configfedora-41-x86_64
project-namemod_http2-2.0.27-1.fc41
store-results-to/tmp/tmp8pemnyw_/mod_http2-2.0.27-1.fc41.tar.xz
time-created2024-07-03 16:15:07
time-finished2024-07-03 16:16:49
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-41-x86_64' '-t' 'cppcheck,gcc,clang,shellcheck' '-o' '/tmp/tmp8pemnyw_/mod_http2-2.0.27-1.fc41.tar.xz' '--gcc-analyze' '/tmp/tmp8pemnyw_/mod_http2-2.0.27-1.fc41.src.rpm'
tool-versioncsmock-3.5.3-1.el9