Newly introduced defects

List of Defects

Error: GCC_ANALYZER_WARNING (CWE-476): [#def1]
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c: scope_hint: In function ‘cJSON_add_array_should_add_array’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:397:32: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:656:133: note: in definition of macro ‘UNITY_TEST_ASSERT_EQUAL_INT’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:397:5: note: in expansion of macro ‘TEST_ASSERT_EQUAL_INT’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:652:102: note: in definition of macro ‘UNITY_TEST_ASSERT’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity.h:125:100: note: in expansion of macro ‘UNITY_TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:396:5: note: in expansion of macro ‘TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/cJSON.c: scope_hint: In function ‘cJSON_add_array_should_add_array’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:652:102: note: in definition of macro ‘UNITY_TEST_ASSERT’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity.h:125:100: note: in expansion of macro ‘UNITY_TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:396:5: note: in expansion of macro ‘TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c: scope_hint: In function ‘cJSON_add_array_should_add_array’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:654:98: note: in expansion of macro ‘UNITY_TEST_ASSERT’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity.h:125:100: note: in expansion of macro ‘UNITY_TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:396:5: note: in expansion of macro ‘TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:652:122: note: in expansion of macro ‘UNITY_TEST_FAIL’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:654:98: note: in expansion of macro ‘UNITY_TEST_ASSERT’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity.h:125:100: note: in expansion of macro ‘UNITY_TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:396:5: note: in expansion of macro ‘TEST_ASSERT_NOT_NULL’
cjson-1.7.17-build/cJSON-1.7.17/tests/unity/src/unity_internals.h:656:133: note: in definition of macro ‘UNITY_TEST_ASSERT_EQUAL_INT’
cjson-1.7.17-build/cJSON-1.7.17/tests/cjson_add.c:397:5: note: in expansion of macro ‘TEST_ASSERT_EQUAL_INT’
#  395|       cJSON_AddArrayToObject(root, "array");
#  396|       TEST_ASSERT_NOT_NULL(array = cJSON_GetObjectItemCaseSensitive(root, "array"));
#  397|->     TEST_ASSERT_EQUAL_INT(array->type, cJSON_Array);
#  398|   
#  399|       cJSON_Delete(root);

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
diffbase-analyzer-version-clang18.1.7
diffbase-analyzer-version-cppcheck2.14.2
diffbase-analyzer-version-gcc14.1.1
diffbase-analyzer-version-gcc-analyzer14.1.1
diffbase-analyzer-version-shellcheck0.10.0
diffbase-enabled-pluginsclang, cppcheck, gcc, shellcheck
diffbase-exit-code0
diffbase-hostip-172-16-1-175.us-west-2.compute.internal
diffbase-mock-configfedora-41-x86_64
diffbase-project-namecjson-1.7.15-4.fc40
diffbase-store-results-to/tmp/tmp9rutcck6/cjson-1.7.15-4.fc40.tar.xz
diffbase-time-created2024-07-03 12:05:46
diffbase-time-finished2024-07-03 12:07:42
diffbase-toolcsmock
diffbase-tool-args'/usr/bin/csmock' '-r' 'fedora-41-x86_64' '-t' 'cppcheck,gcc,clang,shellcheck' '-o' '/tmp/tmp9rutcck6/cjson-1.7.15-4.fc40.tar.xz' '--gcc-analyze' '/tmp/tmp9rutcck6/cjson-1.7.15-4.fc40.src.rpm'
diffbase-tool-versioncsmock-3.5.3-1.el9
enabled-pluginsclang, cppcheck, gcc, shellcheck
exit-code0
hostip-172-16-1-175.us-west-2.compute.internal
mock-configfedora-41-x86_64
project-namecjson-1.7.17-1.fc41
store-results-to/tmp/tmpjq51a04b/cjson-1.7.17-1.fc41.tar.xz
time-created2024-07-03 12:08:10
time-finished2024-07-03 12:09:41
titleNewly introduced defects
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-41-x86_64' '-t' 'cppcheck,gcc,clang,shellcheck' '-o' '/tmp/tmpjq51a04b/cjson-1.7.17-1.fc41.tar.xz' '--gcc-analyze' '/tmp/tmpjq51a04b/cjson-1.7.17-1.fc41.src.rpm'
tool-versioncsmock-3.5.3-1.el9