Error: CPPCHECK_WARNING (CWE-401): [#def1] crun-1.28/libocispec/src/ocispec/basic_test_map_string_string_array.c:159: error[memleak]: Memory leak: ret # 157| ret->maps = calloc (src->maps_len + 1, sizeof (*ret->maps)); # 158| if (ret->maps == NULL) # 159|-> return NULL; # 160| for (size_t i = 0; i < src->maps_len; i++) # 161| { Error: GCC_ANALYZER_WARNING (CWE-401): [#def2] crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:83:16: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(<unknown>)' crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:436:1: enter_function: entry to 'image_spec_schema_content_descriptor_parse_data' crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:443:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:446:5: branch_false: ...to here crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:451:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:462:11: branch_false: ...to here crun-1.28/libocispec/src/ocispec/image_spec_schema_content_descriptor.c:462:11: call_function: calling 'make_image_spec_schema_content_descriptor' from 'image_spec_schema_content_descriptor_parse_data' # 81| const char *str = json_object_get_string (val); # 82| ret->urls[i] = strdup (str ? str : ""); # 83|-> if (ret->urls[i] == NULL) # 84| return NULL; # 85| } Error: GCC_ANALYZER_WARNING (CWE-401): [#def3] crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:395:16: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(<unknown>)' crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:992:1: enter_function: entry to 'image_spec_schema_image_index_schema_parse_data' crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:999:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:1002:5: branch_false: ...to here crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:1007:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:1018:11: branch_false: ...to here crun-1.28/libocispec/src/ocispec/image_spec_schema_image_index_schema.c:1018:11: call_function: calling 'make_image_spec_schema_image_index_schema' from 'image_spec_schema_image_index_schema_parse_data' # 393| const char *str = json_object_get_string (val); # 394| ret->urls[i] = strdup (str ? str : ""); # 395|-> if (ret->urls[i] == NULL) # 396| return NULL; # 397| } Error: GCC_ANALYZER_WARNING (CWE-401): [#def4] crun-1.28/libocispec/src/ocispec/json_common.c:1498:7: warning[-Wanalyzer-malloc-leak]: leak of '<unknown>' crun-1.28/libocispec/src/ocispec/json_common.c:1509:1: enter_function: entry to 'make_json_map_string_int64' crun-1.28/libocispec/src/ocispec/json_common.c:1516:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/json_common.c:1521:13: call_function: calling 'safe_malloc' from 'make_json_map_string_int64' crun-1.28/libocispec/src/ocispec/json_common.c:1521:13: return_function: returning to 'make_json_map_string_int64' from 'safe_malloc' crun-1.28/libocispec/src/ocispec/json_common.c:1523:19: call_function: calling 'safe_malloc' from 'make_json_map_string_int64' crun-1.28/libocispec/src/ocispec/json_common.c:1523:19: return_function: returning to 'make_json_map_string_int64' from 'safe_malloc' crun-1.28/libocispec/src/ocispec/json_common.c:1524:21: call_function: calling 'safe_malloc' from 'make_json_map_string_int64' crun-1.28/libocispec/src/ocispec/json_common.c:1524:21: return_function: returning to 'make_json_map_string_int64' from 'safe_malloc' crun-1.28/libocispec/src/ocispec/json_common.c:1527:7: branch_true: following 'true' branch (when 'entrysrckey' is non-NULL)... crun-1.28/libocispec/src/ocispec/json_common.c:1527:7: call_function: inlined call to 'lh_entry_k' from 'make_json_map_string_int64' crun-1.28/libocispec/src/ocispec/json_common.c:1529:26: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/json_common.c:1529:11: branch_true: ...to here crun-1.28/libocispec/src/ocispec/json_common.c:1529:26: call_function: calling 'safe_strdup' from 'make_json_map_string_int64' crun-1.28/libocispec/src/ocispec/json_common.c:1529:26: return_function: returning to 'make_json_map_string_int64' from 'safe_strdup' crun-1.28/libocispec/src/ocispec/json_common.c:1531:14: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/json_common.c:1535:21: branch_true: ...to here crun-1.28/libocispec/src/ocispec/json_common.c:1535:18: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/json_common.c:1535:70: branch_true: ...to here crun-1.28/libocispec/src/ocispec/json_common.c:1512:70: call_function: inlined call to 'free_json_map_string_int64_function' from 'make_json_map_string_int64' # 1496| map->keys[i] = NULL; # 1497| } # 1498|-> free (map->keys); # 1499| map->keys = NULL; # 1500| free (map->values); Error: GCC_ANALYZER_WARNING (CWE-401): [#def5] crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:2526:16: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(<unknown>)' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3597:1: enter_function: entry to 'make_runtime_spec_schema_config_linux' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3602:8: branch_false: following 'false' branch (when 'tree' is non-NULL)... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3604:11: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3605:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3609:27: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3628:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3628:35: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3628:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3632:27: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3691:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3691:33: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3691:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3695:25: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3696:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3706:25: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3707:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3715:18: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3715:18: call_function: calling 'make_runtime_spec_schema_config_linux_seccomp' from 'make_runtime_spec_schema_config_linux' # 2524| const char *str = json_object_get_string (val); # 2525| ret->flags[i] = strdup (str ? str : ""); # 2526|-> if (ret->flags[i] == NULL) # 2527| return NULL; # 2528| } Error: GCC_ANALYZER_WARNING (CWE-401): [#def6] crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:2572:16: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(<unknown>)' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3597:1: enter_function: entry to 'make_runtime_spec_schema_config_linux' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3602:8: branch_false: following 'false' branch (when 'tree' is non-NULL)... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3604:11: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3605:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3609:27: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3628:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3628:35: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3628:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3632:27: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3691:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3691:33: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3691:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3695:25: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3696:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3706:25: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3707:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3715:18: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_linux.c:3715:18: call_function: calling 'make_runtime_spec_schema_config_linux_seccomp' from 'make_runtime_spec_schema_config_linux' # 2570| const char *str = json_object_get_string (val); # 2571| ret->architectures[i] = strdup (str ? str : ""); # 2572|-> if (ret->architectures[i] == NULL) # 2573| return NULL; # 2574| } Error: GCC_ANALYZER_WARNING (CWE-401): [#def7] crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:1903:16: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(<unknown>)' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:3771:1: enter_function: entry to 'runtime_spec_schema_config_schema_parse_data' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:3778:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:3781:5: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:3786:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:3797:11: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_schema.c:3797:11: call_function: calling 'make_runtime_spec_schema_config_schema' from 'runtime_spec_schema_config_schema_parse_data' # 1901| const char *str = json_object_get_string (val); # 1902| ret->flags[i] = strdup (str ? str : ""); # 1903|-> if (ret->flags[i] == NULL) # 1904| return NULL; # 1905| } Error: GCC_ANALYZER_WARNING (CWE-401): [#def8] crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:711:16: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(<unknown>)' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1053:1: enter_function: entry to 'make_runtime_spec_schema_config_vm' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1058:8: branch_false: following 'false' branch (when 'tree' is non-NULL)... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1060:11: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1061:8: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1063:21: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1064:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1064:34: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1064:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1066:17: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1067:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1067:30: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1067:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1069:16: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1069:16: call_function: calling 'make_runtime_spec_schema_config_vm_image' from 'make_runtime_spec_schema_config_vm' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1069:16: return_function: returning to 'make_runtime_spec_schema_config_vm' from 'make_runtime_spec_schema_config_vm_image' crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1070:6: branch_true: following 'true' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1070:29: branch_true: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1070:7: branch_false: following 'false' branch... crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1072:20: branch_false: ...to here crun-1.28/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1072:20: call_function: calling 'make_runtime_spec_schema_config_vm_hw_config' from 'make_runtime_spec_schema_config_vm' # 709| const char *str = json_object_get_string (val); # 710| ret->dtdevs[i] = strdup (str ? str : ""); # 711|-> if (ret->dtdevs[i] == NULL) # 712| return NULL; # 713| } Error: GCC_ANALYZER_WARNING (CWE-457): [#def9] crun-1.28/src/libcrun/error.c:413:3: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'level' crun-1.28/src/libcrun/error.c:371:1: branch_false: following 'false' branch... crun-1.28/src/libcrun/error.c:371:1: branch_false: ...to here crun-1.28/src/libcrun/error.c:394:6: branch_true: following 'true' branch... crun-1.28/src/libcrun/error.c:397:3: branch_true: ...to here crun-1.28/src/libcrun/error.c:413:3: danger: use of uninitialized value 'level' here # 411| # 412| json_gen_string (gen, "level", strlen ("level")); # 413|-> json_gen_string (gen, level, strlen (level)); # 414| # 415| json_gen_string (gen, "time", strlen ("time")); Error: GCC_ANALYZER_WARNING (CWE-1341): [#def10] crun-1.28/src/libcrun/utils.h:108:5: warning[-Wanalyzer-fd-double-close]: double 'close' of file descriptor 'dfd_clone' crun-1.28/src/libcrun/cgroup-utils.c:1014:1: enter_function: entry to 'libcrun_migrate_all_pids_to_cgroup' crun-1.28/src/libcrun/cgroup-utils.c:1024:6: branch_false: following 'false' branch... crun-1.28/src/libcrun/cgroup-utils.c:1027:9: branch_false: ...to here crun-1.28/src/libcrun/cgroup-utils.c:1027:9: call_function: calling 'libcrun_cgroup_pause_unpause_path' from 'libcrun_migrate_all_pids_to_cgroup' crun-1.28/src/libcrun/cgroup-utils.c:1027:9: return_function: returning to 'libcrun_migrate_all_pids_to_cgroup' from 'libcrun_cgroup_pause_unpause_path' crun-1.28/src/libcrun/cgroup-utils.c:1028:6: branch_false: following 'false' branch... crun-1.28/src/libcrun/cgroup-utils.c:1031:9: branch_false: ...to here crun-1.28/src/libcrun/cgroup-utils.c:1031:9: call_function: calling 'libcrun_cgroup_read_pids_from_path' from 'libcrun_migrate_all_pids_to_cgroup' # 106| int *pp = (int *) p; # 107| if (*pp >= 0) # 108|-> TEMP_FAILURE_RETRY (close (*pp)); # 109| } # 110|
| analyzer-version-clippy | 1.95.0 |
| analyzer-version-cppcheck | 2.20.0 |
| analyzer-version-gcc | 16.1.1 |
| analyzer-version-gcc-analyzer | 16.1.1 |
| analyzer-version-shellcheck | 0.11.0 |
| analyzer-version-unicontrol | 0.0.2 |
| diffbase-analyzer-version-clippy | 1.95.0 |
| diffbase-analyzer-version-cppcheck | 2.20.0 |
| diffbase-analyzer-version-gcc | 16.1.1 |
| diffbase-analyzer-version-gcc-analyzer | 16.1.1 |
| diffbase-analyzer-version-shellcheck | 0.11.0 |
| diffbase-analyzer-version-unicontrol | 0.0.2 |
| diffbase-enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| diffbase-exit-code | 0 |
| diffbase-host | ip-172-16-1-197.us-west-2.compute.internal |
| diffbase-known-false-positives | /usr/share/csmock/known-false-positives.js |
| diffbase-known-false-positives-rpm | known-false-positives-0.0.0.20260524.213755.g3c6d0be.main-1.el9.noarch |
| diffbase-mock-config | fedora-rawhide-x86_64 |
| diffbase-project-name | crun-1.27-1.fc44 |
| diffbase-store-results-to | /tmp/tmph7dy4bwn/crun-1.27-1.fc44.tar.xz |
| diffbase-time-created | 2026-06-01 11:38:04 |
| diffbase-time-finished | 2026-06-01 11:41:05 |
| diffbase-tool | csmock |
| diffbase-tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'shellcheck,cppcheck,clippy,unicontrol,gcc' '-o' '/tmp/tmph7dy4bwn/crun-1.27-1.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmph7dy4bwn/crun-1.27-1.fc44.src.rpm' |
| diffbase-tool-version | csmock-3.8.5.20260529.133039.g6f3b5c6-1.el9 |
| enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| exit-code | 0 |
| host | ip-172-16-1-197.us-west-2.compute.internal |
| known-false-positives | /usr/share/csmock/known-false-positives.js |
| known-false-positives-rpm | known-false-positives-0.0.0.20260524.213755.g3c6d0be.main-1.el9.noarch |
| mock-config | fedora-rawhide-x86_64 |
| project-name | crun-1.28-1.fc45 |
| store-results-to | /tmp/tmp1f5lyvz5/crun-1.28-1.fc45.tar.xz |
| time-created | 2026-06-01 11:41:30 |
| time-finished | 2026-06-01 11:43:51 |
| title | Newly introduced findings |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'shellcheck,cppcheck,clippy,unicontrol,gcc' '-o' '/tmp/tmp1f5lyvz5/crun-1.28-1.fc45.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmp1f5lyvz5/crun-1.28-1.fc45.src.rpm' |
| tool-version | csmock-3.8.5.20260529.133039.g6f3b5c6-1.el9 |