Scan Results

List of Findings

Error: CHECKED_RETURN (CWE-252): [#def1]
/kronosnet/libknet/tests/api_knet_host_set_name.c:32: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:34: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:34: path: Condition "(_fos_res = knet_host_set_name(NULL, 1, "test")) == 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:34: path: Condition "_fos_res == -1", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:34: path: Condition "*__errno_location() != 22", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:40: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:41: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:41: path: Condition "(_fos_res = knet_host_set_name(knet_h1, 2, "test")) == 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:41: path: Condition "_fos_res == -1", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:41: path: Condition "*__errno_location() != 22", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:43: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:44: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:44: path: Condition "(_foe_res = knet_host_add(knet_h1, 1)) != 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:45: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:45: path: Condition "(_foe_res = knet_host_set_name(knet_h1, 1, "test")) != 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:46: path: Condition "strcmp("test", knet_h1->host_index[1]->name)", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:51: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:52: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:52: path: Condition "(_foe_res = knet_host_set_name(knet_h1, 1, "tes")) != 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:53: path: Condition "strcmp("tes", knet_h1->host_index[1]->name)", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:58: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:59: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:59: path: Condition "(_fos_res = knet_host_set_name(knet_h1, 1, NULL)) == 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:59: path: Condition "_fos_res == -1", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:59: path: Condition "*__errno_location() != 22", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:61: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:62: path: Condition "write(logfd, &_log_msg, 256UL /* sizeof (_log_msg) */) != 256UL /* sizeof (_log_msg) */", taking true branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:62: path: Condition "(_foe_res = knet_host_add(knet_h1, 2)) != 0", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:64: path: Condition "!knet_host_set_name(knet_h1, 2, "tes")", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:64: path: Condition "*__errno_location() != 17", taking false branch.
/kronosnet/libknet/tests/api_knet_host_set_name.c:69: check_return: Calling "knet_host_remove" without checking return value (as is done elsewhere 7 out of 8 times).
/kronosnet/libknet/tests/api_knet_handle_free.c:42: example_checked: Example 1: "knet_host_remove(knet_h1, 1)" has its value checked in "(_foe_res = knet_host_remove(knet_h1, 1)) != 0".
/kronosnet/libknet/tests/api_knet_host_get_host_list.c:59: example_checked: Example 2: "knet_host_remove(knet_h1, 1)" has its value checked in "(_foe_res = knet_host_remove(knet_h1, 1)) != 0".
/kronosnet/libknet/tests/api_knet_host_remove.c:36: example_checked: Example 3: "knet_host_remove(NULL, 1)" has its value checked in "(_fos_res = knet_host_remove(NULL, 1)) == 0".
/kronosnet/libknet/tests/api_knet_host_remove.c:59: example_checked: Example 4: "knet_host_remove(knet_h1, 1)" has its value checked in "(_foe_res = knet_host_remove(knet_h1, 1)) != 0".
/kronosnet/libknet/tests/test-common.c:988: example_assign: Example 5: Assigning: "res" = return value from "knet_host_remove(knet_h[h], nodes[i])".
/kronosnet/libknet/tests/test-common.c:989: example_checked: Example 5 (cont.): "res" has its value checked in "res".