Task #111041 - added.err
back to task #111041download
Error: GCC_ANALYZER_WARNING (CWE-476):
crun-HEAD/libocispec/src/ocispec/basic_test_double_array.c:399:9: warning[-Wanalyzer-null-dereference]: dereference of NULL '*ptr.intarrays + i * 8'
crun-HEAD/libocispec/src/ocispec/basic_test_double_array.c: scope_hint: In function 'free_basic_test_double_array'
crun-HEAD/libocispec/src/ocispec/basic_test_double_array.c: scope_hint: In function 'free_basic_test_double_array'
crun-HEAD/libocispec/src/ocispec/basic_test_double_array.c: scope_hint: In function 'free_basic_test_double_array'
crun-HEAD/libocispec/src/ocispec/json_common.h:41:7: note: in definition of macro 'define_cleaner_function'
crun-HEAD/libocispec/src/ocispec/json_common.h:41:7: note: in definition of macro 'define_cleaner_function'
crun-HEAD/libocispec/src/ocispec/basic_test_double_array.c: scope_hint: In function 'free_basic_test_double_array'
# 397| for (i = 0; i < ptr->intarrays_len; i++)
# 398| {
# 399|-> free (ptr->intarrays[i]);
# 400| ptr->intarrays[i] = NULL;
# 401| }
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/basic_test_map_string_string_array.c:185: error[memleak]: Memory leak: ret
# 183| ret->maps = calloc (src->maps_len + 1, sizeof (*ret->maps));
# 184| if (ret->maps == NULL)
# 185|-> return NULL;
# 186| for (size_t i = 0; i < src->maps_len; i++)
# 187| {
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/image_spec_schema_defs.c:181: error[memleak]: Memory leak: ret
# 179| ret->keys = calloc (src->len + 1, sizeof (*ret->keys));
# 180| if (ret->keys == NULL)
# 181|-> return NULL;
# 182| for (i = 0; i < src->len; i++)
# 183| {
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_freebsd.c:373: error[memleak]: Memory leak: ret
# 371| ret->mount = calloc (src->mount_len + 1, sizeof (*ret->mount));
# 372| if (ret->mount == NULL)
# 373|-> return NULL;
# 374| for (size_t i = 0; i < src->mount_len; i++)
# 375| {
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_freebsd.c:992: error[memleak]: Memory leak: ret
# 990| ret->parent = strdup (src->parent);
# 991| if (ret->parent == NULL)
# 992|-> return NULL;
# 993| }
# 994| if (src->host != NULL)
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_freebsd.c:998: error[memleak]: Memory leak: ret
# 996| ret->host = strdup (src->host);
# 997| if (ret->host == NULL)
# 998|-> return NULL;
# 999| }
# 1000| if (src->ip4 != NULL)
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_freebsd.c:1004: error[memleak]: Memory leak: ret
# 1002| ret->ip4 = strdup (src->ip4);
# 1003| if (ret->ip4 == NULL)
# 1004|-> return NULL;
# 1005| }
# 1006| if (src->ip4addr)
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_freebsd.c:1011: error[memleak]: Memory leak: ret
# 1009| ret->ip4addr = calloc (src->ip4addr_len + 1, sizeof (*ret->ip4addr));
# 1010| if (ret->ip4addr == NULL)
# 1011|-> return NULL;
# 1012| for (size_t i = 0; i < src->ip4addr_len; i++)
# 1013| {
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_freebsd.c:1297: error[memleak]: Memory leak: ret
# 1295| ret->devices = calloc (src->devices_len + 1, sizeof (*ret->devices));
# 1296| if (ret->devices == NULL)
# 1297|-> return NULL;
# 1298| for (size_t i = 0; i < src->devices_len; i++)
# 1299| {
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_config_vm.c:1361: error[memleak]: Memory leak: ret
# 1359| ret->hw_config = clone_runtime_spec_schema_config_vm_hw_config (src->hw_config);
# 1360| if (ret->hw_config == NULL)
# 1361|-> return NULL;
# 1362| }
# 1363| return move_ptr (ret);
Error: CPPCHECK_WARNING (CWE-401):
crun-HEAD/libocispec/src/ocispec/runtime_spec_schema_defs_freebsd.c:186: error[memleak]: Memory leak: ret
# 184| ret->path = strdup (src->path);
# 185| if (ret->path == NULL)
# 186|-> return NULL;
# 187| }
# 188| ret->mode = src->mode;
Error: GCC_ANALYZER_WARNING (CWE-457):
crun-HEAD/src/libcrun/error.c: scope_hint: In function 'make_json_error'
crun-HEAD/src/libcrun/error.c:413:3: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'level'
# 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"));