Task #1649 - lksctp-tools-1.0.19-6.fc40/scan-results.err
back to task #1649download
Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/bindx_test.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/bindx_test.c:110:3: warning[unix.Malloc]: Potential leak of memory pointed to by 'buf_ptr' # 108| sd = socket(domain, SOCK_SEQPACKET, IPPROTO_SCTP); # 109| if (sd == -1) { # 110|-> perror("bindx_test: ERROR: Cannot open socket"); # 111| return 1; # 112| } Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/myftp.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-666): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/myftp.c: scope_hint: In function ‘build_endpoint’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/myftp.c:263:22: warning[-Wanalyzer-fd-phase-mismatch]: ‘bind’ on file descriptor ‘retval’ in wrong phase # 261| # 262| /* Bind this socket to the test port. */ # 263|-> if ( bind(retval, (struct sockaddr *)&laddr, sizeof(laddr)) ) { # 264| emsg(argv0,"bind"); # 265| exit(-1); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/nagle_rcv.c:239:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 237| # 238| /* Shut down the link. */ # 239|-> error = 0; # 240| close(sk); # 241| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/nagle_snd.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/nagle_snd.c:351:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 349| printf("\n\n\t\tComplete all the data sendings to receiver...\n\n\n"); # 350| # 351|-> error = 0; # 352| close(sk); # 353| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/peel_client.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/peel_server.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-401): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:1295:16: warning[-Wanalyzer-malloc-leak]: leak of ‘ibitsp’ # 1293| } # 1294| # 1295|-> return error; # 1296| # 1297| } /* command_poll() */ Error: GCC_ANALYZER_WARNING (CWE-401): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:1295:16: warning[-Wanalyzer-malloc-leak]: leak of ‘obitsp’ # 1293| } # 1294| # 1295|-> return error; # 1296| # 1297| } /* command_poll() */ Error: GCC_ANALYZER_WARNING (CWE-401): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c: scope_hint: In function ‘command_poll’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:1295:16: warning[-Wanalyzer-malloc-leak]: leak of ‘xbitsp’ # 1293| } # 1294| # 1295|-> return error; # 1296| # 1297| } /* command_poll() */ Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:1391:33: warning[core.NullDereference]: Access to field 'cmsg_type' results in a dereference of a null pointer # 1389| exit(1); # 1390| } # 1391|-> if (controllen > 0 && event != CMSG_FIRSTHDR(msg)->cmsg_type) { # 1392| fprintf(stderr, "Wrong kind of event: %d, not %d\n", # 1393| CMSG_FIRSTHDR(msg)->cmsg_type, event); Error: GCC_ANALYZER_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c: scope_hint: In function ‘user_test_check_message’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:1391:58: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ /usr/include/sys/socket.h:33: included_from: Included from here. /usr/include/netinet/in.h:23: included_from: Included from here. /usr/include/netdb.h:27: included_from: Included from here. lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:56: included_from: Included from here. # 1389| exit(1); # 1390| } # 1391|-> if (controllen > 0 && event != CMSG_FIRSTHDR(msg)->cmsg_type) { # 1392| fprintf(stderr, "Wrong kind of event: %d, not %d\n", # 1393| CMSG_FIRSTHDR(msg)->cmsg_type, event); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_darn.c:1451:3: warning[unix.MallocSizeof]: Result of 'realloc' is converted to a pointer of type 'struct sockaddr', which is incompatible with sizeof operand type 'struct sockaddr_in6' # 1449| */ # 1450| new_addrs = (struct sockaddr *) # 1451|-> realloc(addrs, sizeof(struct sockaddr_in6) * count); # 1452| # 1453| if (NULL == new_addrs) { Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:441:9: warning[unix.Malloc]: Potential leak of memory pointed to by 'host_s' # 439| } while (error < 0 && i < MAX_BIND_RETRYS); # 440| # 441|-> return 0; # 442| } /* bind_r() */ # 443| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:441:9: warning[unix.Malloc]: Potential leak of memory pointed to by 'serv_s' # 439| } while (error < 0 && i < MAX_BIND_RETRYS); # 440| # 441|-> return 0; # 442| } /* bind_r() */ # 443| Error: GCC_ANALYZER_WARNING (CWE-666): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c: scope_hint: In function ‘connect_r’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:480:17: warning[-Wanalyzer-fd-phase-mismatch]: ‘connect’ on file descriptor ‘sk’ in wrong phase lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:748:9: note: in expansion of macro ‘DEBUG_PRINT’ # 478| # 479| /* Mark sk as being able to accept new associations */ # 480|-> error = connect(sk, serv_addr, addrlen); # 481| if (error != 0) { # 482| fprintf(stderr, "\n\n\t\t*** connect: %s ***\n\n\n", Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:775:7: warning[deadcode.DeadStores]: Although the value stored to 'pid' is used in the enclosing expression, the value is never actually read from 'pid' # 773| } # 774| # 775|-> if ((pid = fork()) == 0) { # 776| settimerhandle(); # 777| printstatus(gsk); Error: GCC_ANALYZER_WARNING (CWE-775): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c: scope_hint: In function ‘printstatus’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:945:1: warning[-Wanalyzer-file-leak]: leak of FILE ‘fp’ # 943| exit(1); # 944| } # 945|-> } Error: GCC_ANALYZER_WARNING (CWE-401): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_status.c:945:1: warning[-Wanalyzer-malloc-leak]: leak of ‘fp’ # 943| exit(1); # 944| } # 945|-> } Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING (CWE-775): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c: scope_hint: In function ‘start_test’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:101:25: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘socket_r()’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:611:9: note: in expansion of macro ‘DEBUG_PRINT’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:624:9: note: in expansion of macro ‘DEBUG_PRINT’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:51: included_from: Included from here. lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:611:9: note: in expansion of macro ‘DEBUG_PRINT’ # 99| #define DEBUG_PRINT(level, print_this...) \ # 100| { \ # 101|-> if (debug_level >= level) { \ # 102| fprintf(stdout, print_this); \ # 103| fflush(stdout); \ Error: GCC_ANALYZER_WARNING (CWE-688): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c: scope_hint: In function ‘append_addr’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:506:18: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘ipaddr’ where non-null expected <built-in>: note: argument 1 of ‘__builtin_strchr’ must be non-null # 504| # 505| /* check the interface. */ # 506|-> ifname = strchr(ipaddr,'%'); # 507| if (ifname) { # 508| *ifname=0; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:543:3: warning[unix.MallocSizeof]: Result of 'realloc' is converted to a pointer of type 'struct sockaddr', which is incompatible with sizeof operand type 'struct sockaddr_in6' # 541| */ # 542| new_addrs = (struct sockaddr *) # 543|-> realloc(addrs, sizeof(struct sockaddr_in6) * count); # 544| # 545| if (NULL == new_addrs) { Error: GCC_ANALYZER_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c: scope_hint: In function ‘bind_r’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:677:25: warning[-Wanalyzer-fd-use-without-check]: ‘bind’ on possibly invalid file descriptor ‘sk’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:673:17: note: in expansion of macro ‘DEBUG_PRINT’ # 675| sk, host_s, serv_s, i+1, MAX_BIND_RETRYS); # 676| # 677|-> error = bind(sk, (struct sockaddr *)saddr, l_len); # 678| # 679| if (error != 0) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:688:14: warning[unix.Malloc]: Potential leak of memory pointed to by 'host_s' # 686| exit(1); # 687| } else { # 688|-> return -1; # 689| } # 690| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:688:14: warning[unix.Malloc]: Potential leak of memory pointed to by 'serv_s' # 686| exit(1); # 687| } else { # 688|-> return -1; # 689| } # 690| } Error: GCC_ANALYZER_WARNING (CWE-666): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c: scope_hint: In function ‘connect_r’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:790:17: warning[-Wanalyzer-fd-phase-mismatch]: ‘connect’ on file descriptor ‘sk’ in wrong phase lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:624:9: note: in expansion of macro ‘DEBUG_PRINT’ # 788| # 789| /* Mark sk as being able to accept new associations */ # 790|-> error = connect(sk, serv_addr, addrlen); # 791| if (error != 0) { # 792| if (do_exit) { Error: GCC_ANALYZER_WARNING (CWE-775): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c: scope_hint: In function ‘mixed_mode_test’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:1194:54: warning[-Wanalyzer-fd-leak]: leak of file descriptor # 1192| # 1193| if (tosend) { # 1194|-> if ((poll_sks[i].assoc_state = (_assoc_state *)malloc( # 1195| sizeof(_assoc_state) * tosend)) == NULL) { # 1196| printf("Can't allocate memory.\n"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_test.c:1255:8: warning[deadcode.DeadStores]: Although the value stored to 'error' is used in the enclosing expression, the value is never actually read from 'error' # 1253| FD_SET(poll_sks[i].sk, xbitsp); # 1254| } # 1255|-> if ((error = select(max_fd + 1, ibitsp, obitsp, xbitsp, # 1256| (struct timeval *)0)) < 0) { # 1257| fprintf(stderr, "\n\t\t*** select() failed "); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:249: error[nullPointer]: Null pointer dereference: diediedie # 247| if (error < 0) { # 248| printf("Send Failure: %s.\n", strerror(errno)); # 249|-> DUMP_CORE; # 250| } # 251| } else { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:249:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 247| if (error < 0) { # 248| printf("Send Failure: %s.\n", strerror(errno)); # 249|-> DUMP_CORE; # 250| } # 251| } else { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:266: error[nullPointer]: Null pointer dereference: diediedie # 264| printf("Send Failure: %s.\n", # 265| strerror(errno)); # 266|-> DUMP_CORE; # 267| } # 268| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:266:5: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 264| printf("Send Failure: %s.\n", # 265| strerror(errno)); # 266|-> DUMP_CORE; # 267| } # 268| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:404: error[nullPointer]: Null pointer dereference: diediedie # 402| if (server_socket < 0) { # 403| printf("Socket Failure: %s.\n", strerror(errno)); # 404|-> DUMP_CORE; # 405| } # 406| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:404:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 402| if (server_socket < 0) { # 403| printf("Socket Failure: %s.\n", strerror(errno)); # 404|-> DUMP_CORE; # 405| } # 406| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:410: error[nullPointer]: Null pointer dereference: diediedie # 408| if (error != 0 ) { # 409| printf("Bind Failure: %s.\n", strerror(errno)); # 410|-> DUMP_CORE; # 411| } # 412| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:410:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 408| if (error != 0 ) { # 409| printf("Bind Failure: %s.\n", strerror(errno)); # 410|-> DUMP_CORE; # 411| } # 412| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:416: error[nullPointer]: Null pointer dereference: diediedie # 414| if (error != 0) { # 415| printf("Listen Failure: %s.\n", strerror(errno)); # 416|-> DUMP_CORE; # 417| } # 418| while (TRUE) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:416:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 414| if (error != 0) { # 415| printf("Listen Failure: %s.\n", strerror(errno)); # 416|-> DUMP_CORE; # 417| } # 418| while (TRUE) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:451: error[nullPointer]: Null pointer dereference: diediedie # 449| if (client_socket[i] < 0 ){ # 450| printf("Socket Failure: %s.\n", strerror(errno)); # 451|-> DUMP_CORE; # 452| } # 453| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:451:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 449| if (client_socket[i] < 0 ){ # 450| printf("Socket Failure: %s.\n", strerror(errno)); # 451|-> DUMP_CORE; # 452| } # 453| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:459: error[nullPointer]: Null pointer dereference: diediedie # 457| if (error < 0) { # 458| printf("Bind Failure: %s\n", strerror(errno)); # 459|-> DUMP_CORE; # 460| } # 461| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:459:5: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 457| if (error < 0) { # 458| printf("Bind Failure: %s\n", strerror(errno)); # 459|-> DUMP_CORE; # 460| } # 461| } Error: GCC_ANALYZER_WARNING (CWE-666): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:466:25: warning[-Wanalyzer-fd-phase-mismatch]: ‘connect’ on file descriptor ‘*client_socket[i]’ in wrong phase lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c: scope_hint: In function ‘client_mode’ # 464| # 465| /* Connect to server and send initial message */ # 466|-> error = connect(client_socket[i], &server_loop.sa, # 467| sizeof(server_loop)); # 468| if (error < 0){ Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:470: error[nullPointer]: Null pointer dereference: diediedie # 468| if (error < 0){ # 469| printf("Connect Failure: %s.\n", strerror(errno)); # 470|-> DUMP_CORE; # 471| } # 472| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:470:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 468| if (error < 0){ # 469| printf("Connect Failure: %s.\n", strerror(errno)); # 470|-> DUMP_CORE; # 471| } # 472| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:489: error[nullPointer]: Null pointer dereference: diediedie # 487| if (error < 0 ) { # 488| printf("Send Failure: %s.\n", strerror(errno)); # 489|-> DUMP_CORE; # 490| } # 491| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:489:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 487| if (error < 0 ) { # 488| printf("Send Failure: %s.\n", strerror(errno)); # 489|-> DUMP_CORE; # 490| } # 491| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/sctp_xconnect.c:514: error[nullPointer]: Null pointer dereference: diediedie # 512| if (error < 0) { # 513| printf("Select Failure: %s.\n", strerror(errno)); # 514|-> DUMP_CORE; # 515| } else if (error) { # 516| /* Loop through the array of sockets to find the ones Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c: scope_hint: In function ‘main’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:131:17: warning[-Wanalyzer-fd-type-mismatch]: ‘accept’ on non-stream-socket file descriptor ‘-1’ # 129| # 130| /* accept() TEST1: Bad socket descriptor EBADF, Expected error */ # 131|-> error = accept(-1, (struct sockaddr *) &acpt_addr, &len); # 132| if (error != -1 || errno != EBADF) # 133| tst_brkm(TBROK, tst_exit, "accept with a bad socket descriptor" Error: GCC_ANALYZER_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:131:17: warning[-Wanalyzer-fd-use-without-check]: ‘accept’ on possibly invalid file descriptor ‘-1’ # 129| # 130| /* accept() TEST1: Bad socket descriptor EBADF, Expected error */ # 131|-> error = accept(-1, (struct sockaddr *) &acpt_addr, &len); # 132| if (error != -1 || errno != EBADF) # 133| tst_brkm(TBROK, tst_exit, "accept with a bad socket descriptor" Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:133: error[nullPointer]: Null pointer dereference: diediedie # 131| error = accept(-1, (struct sockaddr *) &acpt_addr, &len); # 132| if (error != -1 || errno != EBADF) # 133|-> tst_brkm(TBROK, tst_exit, "accept with a bad socket descriptor" # 134| "error:%d, errno:%d", error, errno); # 135| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:142: error[nullPointer]: Null pointer dereference: diediedie # 140| fd = mkstemp(filename); # 141| if (fd == -1) # 142|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 143| filename, strerror(errno)); # 144| error = accept(fd, (struct sockaddr *) &acpt_addr, &len); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:150: error[nullPointer]: Null pointer dereference: diediedie # 148| unlink(filename); # 149| if (error != -1 || err_no != ENOTSOCK) # 150|-> tst_brkm(TBROK, tst_exit, "accept with invalid socket" # 151| "error:%d, errno:%d", error, err_no); # 152| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:158: error[nullPointer]: Null pointer dereference: diediedie # 156| error = accept(lstn_sk, (struct sockaddr *) -1, &len); # 157| if (error != -1 || errno != EFAULT) # 158|-> tst_brkm(TBROK, tst_exit, "accept with invalid address" # 159| "error:%d, errno:%d", error, errno); # 160| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:168: error[nullPointer]: Null pointer dereference: diediedie # 166| error = accept(sk, (struct sockaddr *) &acpt_addr, &len); # 167| if (error != -1 || errno != EINVAL) # 168|-> tst_brkm(TBROK, tst_exit, "accept on a non-listening socket" # 169| "error:%d, errno:%d", error, errno); # 170| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:182: error[nullPointer]: Null pointer dereference: diediedie # 180| error = accept(acpt_sk, (struct sockaddr *) &acpt_addr, &len); # 181| if (error != -1 || (errno != EINVAL && errno != EACCES)) { # 182|-> tst_brkm(TBROK, tst_exit, "accept on an established socket" # 183| "error:%d, errno:%d", error, errno); # 184| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:196: error[nullPointer]: Null pointer dereference: diediedie # 194| acpt_sk = accept(lstn_sk, (struct sockaddr *) &acpt_addr, &len); # 195| if (acpt_sk < 0) # 196|-> tst_brkm(TBROK, tst_exit, "accept a closed association" # 197| "error:%d, errno:%d", error, errno); # 198| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:218: error[nullPointer]: Null pointer dereference: diediedie # 216| error = close(-1); # 217| if (error != -1 || errno != EBADF) # 218|-> tst_brkm(TBROK, tst_exit, "close with a bad socket descriptor " # 219| "error:%d, errno:%d", error, errno); # 220| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:226: error[nullPointer]: Null pointer dereference: diediedie # 224| error = close(sk); # 225| if (error < 0) # 226|-> tst_brkm(TBROK, tst_exit, "close with a valid socket descriptor" # 227| " error:%d, errno:%d", error, errno); # 228| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:234: error[nullPointer]: Null pointer dereference: diediedie # 232| error = close(sk); # 233| if (error != -1 || errno != EBADF) # 234|-> tst_brkm(TBROK, tst_exit, "close with a closed socket " # 235| "descriptor error:%d, errno:%d", error, errno); # 236| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:174: error[nullPointer]: Null pointer dereference: diediedie # 172| error = sctp_getladdrs(-1, 0, &laddrs); # 173| if (error != -1 || errno != EBADF) # 174|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with a bad socket " # 175| "descriptor error:%d, errno:%d", error, errno); # 176| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:174:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 172| error = sctp_getladdrs(-1, 0, &laddrs); # 173| if (error != -1 || errno != EBADF) # 174|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with a bad socket " # 175| "descriptor error:%d, errno:%d", error, errno); # 176| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:184: error[nullPointer]: Null pointer dereference: diediedie # 182| fd = mkstemp(filename); # 183| if (fd == -1) # 184|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 185| filename, strerror(errno)); # 186| error = sctp_getladdrs(fd, 0, &laddrs); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:184:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 182| fd = mkstemp(filename); # 183| if (fd == -1) # 184|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 185| filename, strerror(errno)); # 186| error = sctp_getladdrs(fd, 0, &laddrs); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:192: error[nullPointer]: Null pointer dereference: diediedie # 190| unlink(filename); # 191| if (error != -1 || err_no != ENOTSOCK) # 192|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with invalid socket " # 193| "error:%d, errno:%d", error, err_no); # 194| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:192:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 190| unlink(filename); # 191| if (error != -1 || err_no != ENOTSOCK) # 192|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with invalid socket " # 193| "error:%d, errno:%d", error, err_no); # 194| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:202: error[nullPointer]: Null pointer dereference: diediedie # 200| error = sctp_getladdrs(sk1, 0, &laddrs); # 201| if (error != -1 || errno != EOPNOTSUPP) # 202|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with socket of " # 203| "different protocol error:%d, errno:%d", error, errno); # 204| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:202:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 200| error = sctp_getladdrs(sk1, 0, &laddrs); # 201| if (error != -1 || errno != EOPNOTSUPP) # 202|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with socket of " # 203| "different protocol error:%d, errno:%d", error, errno); # 204| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:211: error[nullPointer]: Null pointer dereference: diediedie # 209| error = sctp_getladdrs(lstn_sk, 0, &laddrs); # 210| if (error < 0) # 211|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with valid socket " # 212| "error:%d, errno:%d", error, errno); # 213| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:211:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 209| error = sctp_getladdrs(lstn_sk, 0, &laddrs); # 210| if (error < 0) # 211|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs with valid socket " # 212| "error:%d, errno:%d", error, errno); # 213| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:218: error[nullPointer]: Null pointer dereference: diediedie # 216| addr->sin_family != lstn_addr.sin_family || # 217| addr->sin_addr.s_addr != lstn_addr.sin_addr.s_addr) # 218|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs comparision failed"); # 219| # 220| tst_resm(TPASS, "sctp_getladdrs() - SUCCESS"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:218:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 216| addr->sin_family != lstn_addr.sin_family || # 217| addr->sin_addr.s_addr != lstn_addr.sin_addr.s_addr) # 218|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs comparision failed"); # 219| # 220| tst_resm(TPASS, "sctp_getladdrs() - SUCCESS"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:224: error[nullPointer]: Null pointer dereference: diediedie # 222| /*sctp_freealddrs() TEST5: freeing the local address*/ # 223| if ((sctp_freeladdrs(laddrs)) < 0) # 224|-> tst_brkm(TBROK, tst_exit, "sctp_freeladdrs " # 225| "error:%d, errno:%d", error, errno); # 226| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:224:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 222| /*sctp_freealddrs() TEST5: freeing the local address*/ # 223| if ((sctp_freeladdrs(laddrs)) < 0) # 224|-> tst_brkm(TBROK, tst_exit, "sctp_freeladdrs " # 225| "error:%d, errno:%d", error, errno); # 226| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:232: error[nullPointer]: Null pointer dereference: diediedie # 230| error = sctp_getpaddrs(-1, 0, &paddrs); # 231| if (error != -1 || errno != EBADF) # 232|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with a bad socket " # 233| "descriptor error:%d, errno:%d", error, errno); # 234| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:232:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 230| error = sctp_getpaddrs(-1, 0, &paddrs); # 231| if (error != -1 || errno != EBADF) # 232|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with a bad socket " # 233| "descriptor error:%d, errno:%d", error, errno); # 234| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:242: error[nullPointer]: Null pointer dereference: diediedie # 240| fd = mkstemp(filename); # 241| if (fd == -1) # 242|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 243| filename, strerror(errno)); # 244| error = sctp_getpaddrs(fd, 0, &paddrs); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:242:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 240| fd = mkstemp(filename); # 241| if (fd == -1) # 242|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 243| filename, strerror(errno)); # 244| error = sctp_getpaddrs(fd, 0, &paddrs); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:250: error[nullPointer]: Null pointer dereference: diediedie # 248| unlink(filename); # 249| if (error != -1 || err_no != ENOTSOCK) # 250|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with invalid socket " # 251| "error:%d, errno:%d", error, err_no); # 252| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:250:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 248| unlink(filename); # 249| if (error != -1 || err_no != ENOTSOCK) # 250|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with invalid socket " # 251| "error:%d, errno:%d", error, err_no); # 252| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:259: error[nullPointer]: Null pointer dereference: diediedie # 257| error = sctp_getpaddrs(sk1, 0, &laddrs); # 258| if (error != -1 || errno != EOPNOTSUPP) # 259|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with socket of " # 260| "different protocol error:%d, errno:%d", error, errno); # 261| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:259:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 257| error = sctp_getpaddrs(sk1, 0, &laddrs); # 258| if (error != -1 || errno != EOPNOTSUPP) # 259|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with socket of " # 260| "different protocol error:%d, errno:%d", error, errno); # 261| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:268: error[nullPointer]: Null pointer dereference: diediedie # 266| error = sctp_getpaddrs(acpt_sk, 0, &paddrs); # 267| if (error < 0) # 268|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with valid socket " # 269| "error:%d, errno:%d", error, errno); # 270| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:268:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 266| error = sctp_getpaddrs(acpt_sk, 0, &paddrs); # 267| if (error < 0) # 268|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs with valid socket " # 269| "error:%d, errno:%d", error, errno); # 270| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:275: error[nullPointer]: Null pointer dereference: diediedie # 273| addr->sin_family != acpt_addr.sin_family || # 274| addr->sin_addr.s_addr != acpt_addr.sin_addr.s_addr) # 275|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs comparision failed"); # 276| # 277| tst_resm(TPASS, "sctp_getpaddrs() - SUCCESS"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:275:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 273| addr->sin_family != acpt_addr.sin_family || # 274| addr->sin_addr.s_addr != acpt_addr.sin_addr.s_addr) # 275|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs comparision failed"); # 276| # 277| tst_resm(TPASS, "sctp_getpaddrs() - SUCCESS"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:281: error[nullPointer]: Null pointer dereference: diediedie # 279| /*sctp_freeapddrs() TEST10: freeing the peer address*/ # 280| if ((sctp_freepaddrs(paddrs)) < 0) # 281|-> tst_brkm(TBROK, tst_exit, "sctp_freepaddrs " # 282| "error:%d, errno:%d", error, errno); # 283| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_addrs.c:281:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 279| /*sctp_freeapddrs() TEST10: freeing the peer address*/ # 280| if ((sctp_freepaddrs(paddrs)) < 0) # 281|-> tst_brkm(TBROK, tst_exit, "sctp_freepaddrs " # 282| "error:%d, errno:%d", error, errno); # 283| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: GCC_ANALYZER_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c: scope_hint: In function ‘main’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:117:17: warning[-Wanalyzer-fd-use-without-check]: ‘connect’ on possibly invalid file descriptor ‘-1’ # 115| /*connect () TEST1: Bad socket descriptor, EBADF Expected error*/ # 116| len = sizeof(struct sockaddr_in); # 117|-> error = connect(-1, (const struct sockaddr *) &conn_addr, len); # 118| if (error != -1 || errno != EBADF) # 119| tst_brkm(TBROK, tst_exit, "connect with bad socket " Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:119: error[nullPointer]: Null pointer dereference: diediedie # 117| error = connect(-1, (const struct sockaddr *) &conn_addr, len); # 118| if (error != -1 || errno != EBADF) # 119|-> tst_brkm(TBROK, tst_exit, "connect with bad socket " # 120| "descriptor error:%d, errno:%d", error, errno); # 121| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:128: error[nullPointer]: Null pointer dereference: diediedie # 126| fd = mkstemp(filename); # 127| if (fd == -1) # 128|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 129| filename, strerror(errno)); # 130| error = connect(fd, (const struct sockaddr *) &conn_addr, len); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:136: error[nullPointer]: Null pointer dereference: diediedie # 134| unlink(filename); # 135| if (error != -1 || err_no != ENOTSOCK) # 136|-> tst_brkm(TBROK, tst_exit, "connect with invalid socket " # 137| "error:%d, errno:%d", error, err_no); # 138| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:144: error[nullPointer]: Null pointer dereference: diediedie # 142| error = connect(sk, (const struct sockaddr *) -1, len); # 143| if (error != -1 || errno != EFAULT) # 144|-> tst_brkm(TBROK, tst_exit, "connect with invalid address " # 145| "error:%d, errno:%d", error, errno); # 146| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:152: error[nullPointer]: Null pointer dereference: diediedie # 150| error = connect(sk, (const struct sockaddr *) &conn_addr, (len - 3)); # 151| if (error != -1 || errno != EINVAL) # 152|-> tst_brkm(TBROK, tst_exit, "connect with invalid address length " # 153| "error:%d, errno:%d", error, errno); # 154| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:161: error[nullPointer]: Null pointer dereference: diediedie # 159| error = connect(sk, (const struct sockaddr *) &conn_addr, len); # 160| if (error != -1 || errno != EINVAL) # 161|-> tst_brkm(TBROK, tst_exit, "connect with invalid address family " # 162| "error:%d, errno:%d", error, errno); # 163| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:175: error[nullPointer]: Null pointer dereference: diediedie # 173| len); # 174| if (error < 0) # 175|-> tst_brkm(TBROK, tst_exit, "valid blocking connect " # 176| "error:%d, errno:%d", error, errno); # 177| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:186: error[nullPointer]: Null pointer dereference: diediedie # 184| error = connect(clnt2_sk, (const struct sockaddr *) &conn_addr, len); # 185| if (error != -1 || errno != ECONNREFUSED) # 186|-> tst_brkm(TBROK, tst_exit, "connect when accept queue is full " # 187| "error:%d, errno:%d", error, errno); # 188| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:199: error[nullPointer]: Null pointer dereference: diediedie # 197| error = connect(lstn_sk, (const struct sockaddr *) &lstn_addr, len); # 198| if (error != -1 || errno != EISCONN) # 199|-> tst_brkm(TBROK, tst_exit, "connect on a listening socket " # 200| "error:%d, errno:%d", error, errno); # 201| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:208: error[nullPointer]: Null pointer dereference: diediedie # 206| error = connect(acpt_sk[i], (const struct sockaddr *) &lstn_addr, len); # 207| if (error != -1 || errno != EISCONN) # 208|-> tst_brkm(TBROK, tst_exit, "connect on an established socket " # 209| "error:%d, errno:%d", error, errno); # 210| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connect.c:223: error[nullPointer]: Null pointer dereference: diediedie # 221| error = connect(sk1, (const struct sockaddr *)&conn_addr, len); # 222| if (error < 0) # 223|-> tst_brkm(TBROK, tst_exit, "Re-establish an association that " # 224| "is closed error:%d, errno:%d", error, errno); # 225| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:118: error[nullPointer]: Null pointer dereference: diediedie # 116| error = sctp_connectx(-1, (struct sockaddr *) &conn_addr, 1, NULL); # 117| if (error != -1 || errno != EBADF) # 118|-> tst_brkm(TBROK, tst_exit, "sctp_connectx with bad socket " # 119| "descriptor error:%d, errno:%d", error, errno); # 120| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:126: error[nullPointer]: Null pointer dereference: diediedie # 124| error = sctp_connectx(0, (struct sockaddr *) &conn_addr, 1, NULL); # 125| if (error != -1 || errno != ENOTSOCK) # 126|-> tst_brkm(TBROK, tst_exit, "sctp_connectx with invalid socket " # 127| "error:%d, errno:%d", error, errno); # 128| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:136: error[nullPointer]: Null pointer dereference: diediedie # 134| error = sctp_connectx(sk, tmp_addr, 1, NULL); # 135| if (error != -1 || errno != EINVAL) # 136|-> tst_brkm(TBROK, tst_exit, "sctp_connectx with invalid address " # 137| "error:%d, errno:%d", error, errno); # 138| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:144: error[nullPointer]: Null pointer dereference: diediedie # 142| error = sctp_connectx(sk, (struct sockaddr *) &conn_addr, 0, NULL); # 143| if (error != -1 || errno != EINVAL) # 144|-> tst_brkm(TBROK, tst_exit, "sctp_connectx with invalid address length " # 145| "error:%d, errno:%d", error, errno); # 146| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:153: error[nullPointer]: Null pointer dereference: diediedie # 151| error = sctp_connectx(sk, (struct sockaddr *) &conn_addr, 1, NULL); # 152| if (error != -1 || errno != EINVAL) # 153|-> tst_brkm(TBROK, tst_exit, "sctp_connectx with invalid address family " # 154| "error:%d, errno:%d", error, errno); # 155| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:167: error[nullPointer]: Null pointer dereference: diediedie # 165| 1, NULL); # 166| if (error < 0) # 167|-> tst_brkm(TBROK, tst_exit, "valid blocking sctp_connectx " # 168| "error:%d, errno:%d", error, errno); # 169| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:178: error[nullPointer]: Null pointer dereference: diediedie # 176| error = sctp_connectx(clnt2_sk, (struct sockaddr *) &conn_addr, 1, NULL); # 177| if (error != -1 || errno != ECONNREFUSED) # 178|-> tst_brkm(TBROK, tst_exit, "sctp_connectx when accept queue is full " # 179| "error:%d, errno:%d", error, errno); # 180| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:191: error[nullPointer]: Null pointer dereference: diediedie # 189| error = sctp_connectx(lstn_sk, (struct sockaddr *) &lstn_addr, 1, NULL); # 190| if (error != -1 || errno != EISCONN) # 191|-> tst_brkm(TBROK, tst_exit, "sctp_connectx on a listening socket " # 192| "error:%d, errno:%d", error, errno); # 193| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:200: error[nullPointer]: Null pointer dereference: diediedie # 198| error = sctp_connectx(acpt_sk[i], (struct sockaddr *) &lstn_addr, 1, NULL); # 199| if (error != -1 || errno != EISCONN) # 200|-> tst_brkm(TBROK, tst_exit, "sctp_connectx on an established socket " # 201| "error:%d, errno:%d", error, errno); # 202| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_connectx.c:215: error[nullPointer]: Null pointer dereference: diediedie # 213| error = sctp_connectx(sk1, (struct sockaddr *)&conn_addr, 1, NULL); # 214| if (error < 0) # 215|-> tst_brkm(TBROK, tst_exit, "Re-establish an association that " # 216| "is closed error:%d, errno:%d", error, errno); # 217| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_events.c:143: error[nullPointer]: Null pointer dereference: diediedie # 141| /* NOW initialize inmessage with enough space for DATA... */ # 142| big_buffer = malloc(REALLY_BIG); # 143|-> if (!big_buffer) { DUMP_CORE; } # 144| # 145| /* Let's do a test to do a recvmsg when we are not listening and Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_events.c:143:21: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 141| /* NOW initialize inmessage with enough space for DATA... */ # 142| big_buffer = malloc(REALLY_BIG); # 143|-> if (!big_buffer) { DUMP_CORE; } # 144| # 145| /* Let's do a test to do a recvmsg when we are not listening and Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:114: error[nullPointer]: Null pointer dereference: diediedie # 112| sflag = fcntl(lstn_sk, F_GETFL, 0); # 113| if (sflag < 0) # 114|-> tst_brkm(TBROK, tst_exit, "fcnt F_GETFL failed " # 115| "sflag:%d, errno:%d", sflag, errno); # 116| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:114:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 112| sflag = fcntl(lstn_sk, F_GETFL, 0); # 113| if (sflag < 0) # 114|-> tst_brkm(TBROK, tst_exit, "fcnt F_GETFL failed " # 115| "sflag:%d, errno:%d", sflag, errno); # 116| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:119: error[nullPointer]: Null pointer dereference: diediedie # 117| error = fcntl(lstn_sk, F_SETFL, sflag | O_NONBLOCK); # 118| if (error < 0) # 119|-> tst_brkm(TBROK, tst_exit, "fcnt F_SETFL failed " # 120| "error:%d, errno:%d", error, errno); # 121| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:119:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 117| error = fcntl(lstn_sk, F_SETFL, sflag | O_NONBLOCK); # 118| if (error < 0) # 119|-> tst_brkm(TBROK, tst_exit, "fcnt F_SETFL failed " # 120| "error:%d, errno:%d", error, errno); # 121| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:125: error[nullPointer]: Null pointer dereference: diediedie # 123| error = accept(lstn_sk, (struct sockaddr *)&svr_addr, &len); # 124| if (error != -1 || errno != EAGAIN) # 125|-> tst_brkm(TBROK, tst_exit, "non-blocking accept " # 126| "error:%d, errno:%d", error, errno); # 127| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:125:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 123| error = accept(lstn_sk, (struct sockaddr *)&svr_addr, &len); # 124| if (error != -1 || errno != EAGAIN) # 125|-> tst_brkm(TBROK, tst_exit, "non-blocking accept " # 126| "error:%d, errno:%d", error, errno); # 127| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:134: error[nullPointer]: Null pointer dereference: diediedie # 132| cflag = fcntl(sk, F_GETFL, 0); # 133| if (cflag < 0) # 134|-> tst_brkm(TBROK, tst_exit, "fcnt F_GETFL failed " # 135| "cflag:%d, errno:%d", cflag, errno); # 136| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:134:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 132| cflag = fcntl(sk, F_GETFL, 0); # 133| if (cflag < 0) # 134|-> tst_brkm(TBROK, tst_exit, "fcnt F_GETFL failed " # 135| "cflag:%d, errno:%d", cflag, errno); # 136| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:139: error[nullPointer]: Null pointer dereference: diediedie # 137| error = fcntl(sk, F_SETFL, sflag | O_NONBLOCK); # 138| if (error < 0) # 139|-> tst_brkm(TBROK, tst_exit, "fcnt F_SETFL failed " # 140| "error:%d, errno:%d", error, errno); # 141| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:139:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 137| error = fcntl(sk, F_SETFL, sflag | O_NONBLOCK); # 138| if (error < 0) # 139|-> tst_brkm(TBROK, tst_exit, "fcnt F_SETFL failed " # 140| "error:%d, errno:%d", error, errno); # 141| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:144: error[nullPointer]: Null pointer dereference: diediedie # 142| error = connect(sk, (const struct sockaddr *) &conn_addr, len); # 143| if (error != -1 || errno != EINPROGRESS) # 144|-> tst_brkm(TBROK, tst_exit, "non-blocking connect " # 145| "error:%d, errno:%d", error, errno); # 146| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:144:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 142| error = connect(sk, (const struct sockaddr *) &conn_addr, len); # 143| if (error != -1 || errno != EINPROGRESS) # 144|-> tst_brkm(TBROK, tst_exit, "non-blocking connect " # 145| "error:%d, errno:%d", error, errno); # 146| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:152: error[nullPointer]: Null pointer dereference: diediedie # 150| acpt_sk = accept(lstn_sk, (struct sockaddr *)&svr_addr, &len); # 151| if (acpt_sk < 0) # 152|-> tst_brkm(TBROK, tst_exit, "accept after a non-blocking connect " # 153| "error:%d, errno:%d", error, errno); # 154| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:152:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 150| acpt_sk = accept(lstn_sk, (struct sockaddr *)&svr_addr, &len); # 151| if (acpt_sk < 0) # 152|-> tst_brkm(TBROK, tst_exit, "accept after a non-blocking connect " # 153| "error:%d, errno:%d", error, errno); # 154| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:192: error[nullPointer]: Null pointer dereference: diediedie # 190| error = recvmsg(sk, &inmessage, MSG_WAITALL); # 191| if ( error != -1 || errno != EAGAIN) # 192|-> tst_brkm(TBROK, tst_exit, "non-blocking recvmsg " # 193| "error:%d, errno:%d", error, errno); # 194| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:192:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 190| error = recvmsg(sk, &inmessage, MSG_WAITALL); # 191| if ( error != -1 || errno != EAGAIN) # 192|-> tst_brkm(TBROK, tst_exit, "non-blocking recvmsg " # 193| "error:%d, errno:%d", error, errno); # 194| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:115:2: warning[deadcode.DeadStores]: Value stored to 'count' is never read # 113| flag = MSG_NOSIGNAL; # 114| /*Sending the message*/ # 115|-> count = test_send(sk, message, msg_count, flag); # 116| # 117| /*recvfrom () TEST1: Bad socket descriptor, EBADF Expected error*/ Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:121: error[nullPointer]: Null pointer dereference: diediedie # 119| (struct sockaddr *)&svr_addr, &len); # 120| if (count != -1 || errno != EBADF) # 121|-> tst_brkm(TBROK, tst_exit, "recvfrom with a bad socket " # 122| "descriptor count:%d, errno:%d", count, errno); # 123| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:121:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 119| (struct sockaddr *)&svr_addr, &len); # 120| if (count != -1 || errno != EBADF) # 121|-> tst_brkm(TBROK, tst_exit, "recvfrom with a bad socket " # 122| "descriptor count:%d, errno:%d", count, errno); # 123| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:130: error[nullPointer]: Null pointer dereference: diediedie # 128| fd = mkstemp(filename); # 129| if (fd == -1) # 130|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 131| filename, strerror(errno)); # 132| count = recvfrom(fd, message_rcv, msg_count, flag, Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:130:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 128| fd = mkstemp(filename); # 129| if (fd == -1) # 130|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 131| filename, strerror(errno)); # 132| count = recvfrom(fd, message_rcv, msg_count, flag, Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:139: error[nullPointer]: Null pointer dereference: diediedie # 137| unlink(filename); # 138| if (count != -1 || err_no != ENOTSOCK) # 139|-> tst_brkm(TBROK, tst_exit, "recvfrom with invalid socket " # 140| "count:%d, errno:%d", count, err_no); # 141| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:139:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 137| unlink(filename); # 138| if (count != -1 || err_no != ENOTSOCK) # 139|-> tst_brkm(TBROK, tst_exit, "recvfrom with invalid socket " # 140| "count:%d, errno:%d", count, err_no); # 141| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:148: error[nullPointer]: Null pointer dereference: diediedie # 146| (struct sockaddr *)&svr_addr, &len); # 147| if (count != -1 || errno != EFAULT) # 148|-> tst_brkm(TBROK, tst_exit, "recvfrom with invalid message " # 149| "pointer count:%d, errno:%d", count, errno); # 150| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:148:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 146| (struct sockaddr *)&svr_addr, &len); # 147| if (count != -1 || errno != EFAULT) # 148|-> tst_brkm(TBROK, tst_exit, "recvfrom with invalid message " # 149| "pointer count:%d, errno:%d", count, errno); # 150| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:157: error[nullPointer]: Null pointer dereference: diediedie # 155| (struct sockaddr *)&svr_addr, &len); # 156| if (count != -1 || errno != ENOTCONN) # 157|-> tst_brkm(TBROK, tst_exit, "recvfrom on listening socket " # 158| "count:%d, errno:%d", count, errno); # 159| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:157:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 155| (struct sockaddr *)&svr_addr, &len); # 156| if (count != -1 || errno != ENOTCONN) # 157|-> tst_brkm(TBROK, tst_exit, "recvfrom on listening socket " # 158| "count:%d, errno:%d", count, errno); # 159| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:162:2: warning[deadcode.DeadStores]: Value stored to 'count' is never read # 160| tst_resm(TPASS, "recvfrom() on listening socket - ENOTCONN"); # 161| # 162|-> count = test_send(acpt_sk, message, msg_count, flag); # 163| # 164| test_shutdown(sk, SHUT_WR); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:170: error[nullPointer]: Null pointer dereference: diediedie # 168| (struct sockaddr *)&svr_addr, &len); # 169| if (count < 0) # 170|-> tst_brkm(TBROK, tst_exit, "recvfrom on a socket that has " # 171| "received shutdown count:%d, errno:%d", count, errno); # 172| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:170:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 168| (struct sockaddr *)&svr_addr, &len); # 169| if (count < 0) # 170|-> tst_brkm(TBROK, tst_exit, "recvfrom on a socket that has " # 171| "received shutdown count:%d, errno:%d", count, errno); # 172| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:181: error[nullPointer]: Null pointer dereference: diediedie # 179| (struct sockaddr *)&svr_addr, &len); # 180| if (count < 0) # 181|-> tst_brkm(TBROK, tst_exit, "recvfrom on a socket with pending " # 182| "message that has sent shutdown count:%d, errno:%d", # 183| count, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:181:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 179| (struct sockaddr *)&svr_addr, &len); # 180| if (count < 0) # 181|-> tst_brkm(TBROK, tst_exit, "recvfrom on a socket with pending " # 182| "message that has sent shutdown count:%d, errno:%d", # 183| count, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:193: error[nullPointer]: Null pointer dereference: diediedie # 191| (struct sockaddr *)&svr_addr, &len); # 192| if (count != -1 || errno != ENOTCONN) # 193|-> tst_brkm(TBROK, tst_exit, "recvfrom on a socket with no " # 194| "pending messages and has sent shutdown count:%d, " # 195| "errno:%d", count, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvfrom.c:193:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 191| (struct sockaddr *)&svr_addr, &len); # 192| if (count != -1 || errno != ENOTCONN) # 193|-> tst_brkm(TBROK, tst_exit, "recvfrom on a socket with no " # 194| "pending messages and has sent shutdown count:%d, " # 195| "errno:%d", count, errno); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:127: error[nullPointer]: Null pointer dereference: diediedie # 125| count = recvmsg(-1, &inmessage, flag); # 126| if (count != -1 || errno != EBADF) # 127|-> tst_brkm(TBROK, tst_exit, "recvmsg with a bad socket " # 128| "descriptor count:%d, errno:%d", count, errno); # 129| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:127:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 125| count = recvmsg(-1, &inmessage, flag); # 126| if (count != -1 || errno != EBADF) # 127|-> tst_brkm(TBROK, tst_exit, "recvmsg with a bad socket " # 128| "descriptor count:%d, errno:%d", count, errno); # 129| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:136: error[nullPointer]: Null pointer dereference: diediedie # 134| fd = mkstemp(filename); # 135| if (fd == -1) # 136|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 137| filename, strerror(errno)); # 138| count = recvmsg(fd, &inmessage, flag); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:136:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 134| fd = mkstemp(filename); # 135| if (fd == -1) # 136|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 137| filename, strerror(errno)); # 138| count = recvmsg(fd, &inmessage, flag); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:144: error[nullPointer]: Null pointer dereference: diediedie # 142| unlink(filename); # 143| if (count != -1 || err_no != ENOTSOCK) # 144|-> tst_brkm(TBROK, tst_exit, "recvmsg with invalid socket " # 145| "count:%d, errno:%d", count, err_no); # 146| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:144:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 142| unlink(filename); # 143| if (count != -1 || err_no != ENOTSOCK) # 144|-> tst_brkm(TBROK, tst_exit, "recvmsg with invalid socket " # 145| "count:%d, errno:%d", count, err_no); # 146| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:153: error[nullPointer]: Null pointer dereference: diediedie # 151| count = recvmsg(acpt_sk, &inmessage, flag); # 152| if (count != -1 || errno != EFAULT) # 153|-> tst_brkm(TBROK, tst_exit, "recvmsg with invalid iovec " # 154| "pointer count:%d, errno:%d", count, errno); # 155| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:153:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 151| count = recvmsg(acpt_sk, &inmessage, flag); # 152| if (count != -1 || errno != EFAULT) # 153|-> tst_brkm(TBROK, tst_exit, "recvmsg with invalid iovec " # 154| "pointer count:%d, errno:%d", count, errno); # 155| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:163: error[nullPointer]: Null pointer dereference: diediedie # 161| count = recvmsg(acpt_sk, (struct msghdr *)-1, flag); # 162| if (count != -1 || errno != EFAULT) # 163|-> tst_brkm(TBROK, tst_exit, "recvmsg with invalid msghdr " # 164| "pointer count:%d, errno:%d", count, errno); # 165| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:163:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 161| count = recvmsg(acpt_sk, (struct msghdr *)-1, flag); # 162| if (count != -1 || errno != EFAULT) # 163|-> tst_brkm(TBROK, tst_exit, "recvmsg with invalid msghdr " # 164| "pointer count:%d, errno:%d", count, errno); # 165| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:171: error[nullPointer]: Null pointer dereference: diediedie # 169| count = recvmsg(lstn_sk, &inmessage, flag); # 170| if (count != -1 || errno != ENOTCONN) # 171|-> tst_brkm(TBROK, tst_exit, "recvmsg on listening socket " # 172| "count:%d, errno:%d", count, errno); # 173| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:171:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 169| count = recvmsg(lstn_sk, &inmessage, flag); # 170| if (count != -1 || errno != ENOTCONN) # 171|-> tst_brkm(TBROK, tst_exit, "recvmsg on listening socket " # 172| "count:%d, errno:%d", count, errno); # 173| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:176:2: warning[deadcode.DeadStores]: Value stored to 'count' is never read # 174| tst_resm(TPASS, "recvmsg() on listening socket - ENOTCONN"); # 175| # 176|-> count = test_send(acpt_sk, message1, strlen(message), 0); # 177| # 178| test_shutdown(sk, SHUT_WR); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:184: error[nullPointer]: Null pointer dereference: diediedie # 182| count = recvmsg(acpt_sk, &inmessage, flag); # 183| if (count < 0) # 184|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket that has " # 185| "received shutdown count:%d, errno:%d", count, errno); # 186| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:184:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 182| count = recvmsg(acpt_sk, &inmessage, flag); # 183| if (count < 0) # 184|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket that has " # 185| "received shutdown count:%d, errno:%d", count, errno); # 186| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:194: error[nullPointer]: Null pointer dereference: diediedie # 192| count = recvmsg(sk, &inmessage, flag); # 193| if (count < 0) # 194|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket with pending " # 195| "message that has sent shutdown count:%d, errno:%d", # 196| count, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:194:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 192| count = recvmsg(sk, &inmessage, flag); # 193| if (count < 0) # 194|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket with pending " # 195| "message that has sent shutdown count:%d, errno:%d", # 196| count, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:205: error[nullPointer]: Null pointer dereference: diediedie # 203| count = recvmsg(sk, &inmessage, flag); # 204| if (count != -1 || errno != ENOTCONN) # 205|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket with no " # 206| "pending messages and has sent shutdown count:%d, " # 207| "errno:%d", count, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_recvmsg.c:205:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 203| count = recvmsg(sk, &inmessage, flag); # 204| if (count != -1 || errno != ENOTCONN) # 205|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket with no " # 206| "pending messages and has sent shutdown count:%d, " # 207| "errno:%d", count, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:76: error[nullPointer]: Null pointer dereference: diediedie # 74| ret = getsockopt(sd, IPPROTO_SCTP, SCTP_RTOINFO, &grtoinfo, &len); # 75| if (ret < 0) # 76|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_RTOINFO " # 77| "ret:%d, errno:%d", ret, errno); # 78| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:76:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 74| ret = getsockopt(sd, IPPROTO_SCTP, SCTP_RTOINFO, &grtoinfo, &len); # 75| if (ret < 0) # 76|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_RTOINFO " # 77| "ret:%d, errno:%d", ret, errno); # 78| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:91: error[nullPointer]: Null pointer dereference: diediedie # 89| sizeof(struct sctp_rtoinfo)); # 90| if (ret < 0) # 91|-> tst_brkm(TBROK, tst_exit, "setsockopt SCTP_RTOINFO " # 92| "ret:%d, errno:%d", ret, errno); # 93| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:91:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 89| sizeof(struct sctp_rtoinfo)); # 90| if (ret < 0) # 91|-> tst_brkm(TBROK, tst_exit, "setsockopt SCTP_RTOINFO " # 92| "ret:%d, errno:%d", ret, errno); # 93| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:99: error[nullPointer]: Null pointer dereference: diediedie # 97| ret = getsockopt(sd, IPPROTO_SCTP, SCTP_RTOINFO, &grtoinfo, &len); # 98| if (ret < 0) # 99|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_RTOINFO " # 100| "ret:%d, errno:%d", ret, errno); # 101| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:99:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 97| ret = getsockopt(sd, IPPROTO_SCTP, SCTP_RTOINFO, &grtoinfo, &len); # 98| if (ret < 0) # 99|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_RTOINFO " # 100| "ret:%d, errno:%d", ret, errno); # 101| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:106: error[nullPointer]: Null pointer dereference: diediedie # 104| srtoinfo.srto_max != grtoinfo.srto_max && # 105| srtoinfo.srto_min != grtoinfo.srto_min) # 106|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SCTP_RTOINFO " # 107| "compare failed"); # 108| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_rtoinfo.c:106:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 104| srtoinfo.srto_max != grtoinfo.srto_max && # 105| srtoinfo.srto_min != grtoinfo.srto_min) # 106|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SCTP_RTOINFO " # 107| "compare failed"); # 108| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:117: error[nullPointer]: Null pointer dereference: diediedie # 115| count = send(-1, message, len_snd, flag); # 116| if (count != -1 || errno != EBADF) # 117|-> tst_brkm(TBROK, tst_exit, "send with a bad socket " # 118| "descriptor count:%d, errno:%d", count, errno); # 119| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:117:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 115| count = send(-1, message, len_snd, flag); # 116| if (count != -1 || errno != EBADF) # 117|-> tst_brkm(TBROK, tst_exit, "send with a bad socket " # 118| "descriptor count:%d, errno:%d", count, errno); # 119| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:126: error[nullPointer]: Null pointer dereference: diediedie # 124| fd = mkstemp(filename); # 125| if (fd == -1) # 126|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 127| filename, strerror(errno)); # 128| count = send(fd, message, len_snd, flag); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:126:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 124| fd = mkstemp(filename); # 125| if (fd == -1) # 126|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 127| filename, strerror(errno)); # 128| count = send(fd, message, len_snd, flag); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:134: error[nullPointer]: Null pointer dereference: diediedie # 132| unlink(filename); # 133| if (count != -1 || err_no != ENOTSOCK) # 134|-> tst_brkm(TBROK, tst_exit, "send with invalid socket " # 135| "count:%d, errno:%d", count, err_no); # 136| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:134:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 132| unlink(filename); # 133| if (count != -1 || err_no != ENOTSOCK) # 134|-> tst_brkm(TBROK, tst_exit, "send with invalid socket " # 135| "count:%d, errno:%d", count, err_no); # 136| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:142: error[nullPointer]: Null pointer dereference: diediedie # 140| count = send(lstn_sk, message, len_snd, flag); # 141| if (count != -1 || errno != EPIPE) # 142|-> tst_brkm(TBROK, tst_exit, "send on a listening socket " # 143| "count:%d, errno:%d", count, errno); # 144| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:142:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 140| count = send(lstn_sk, message, len_snd, flag); # 141| if (count != -1 || errno != EPIPE) # 142|-> tst_brkm(TBROK, tst_exit, "send on a listening socket " # 143| "count:%d, errno:%d", count, errno); # 144| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:159:2: warning[deadcode.DeadStores]: Value stored to 'count' is never read # 157| test_connect(sk1, (struct sockaddr *) &lstn_addr, len); # 158| # 159|-> count = test_send(sk1, message, len_snd, flag); # 160| # 161| close(sk1); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:168: error[nullPointer]: Null pointer dereference: diediedie # 166| count = send(acpt1_sk, message, len_snd, flag); # 167| if (count != -1 || errno != EPIPE) # 168|-> tst_brkm(TBROK, tst_exit, "send on a closed association " # 169| "count:%d, errno:%d", count, errno); # 170| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:168:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 166| count = send(acpt1_sk, message, len_snd, flag); # 167| if (count != -1 || errno != EPIPE) # 168|-> tst_brkm(TBROK, tst_exit, "send on a closed association " # 169| "count:%d, errno:%d", count, errno); # 170| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:205: error[nullPointer]: Null pointer dereference: diediedie # 203| count = send(sk, message, msg_count, flag); # 204| if (count != msg_count) # 205|-> tst_brkm(TBROK, tst_exit, "send from client to server " # 206| "count:%d, errno:%d", count, errno); # 207| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:205:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 203| count = send(sk, message, msg_count, flag); # 204| if (count != msg_count) # 205|-> tst_brkm(TBROK, tst_exit, "send from client to server " # 206| "count:%d, errno:%d", count, errno); # 207| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:217: error[nullPointer]: Null pointer dereference: diediedie # 215| count = send(acpt_sk, message, msg_count, flag); # 216| if (count != msg_count) # 217|-> tst_brkm(TBROK, tst_exit, "send from accept socket to client " # 218| "count:%d, errno:%d", count, errno); # 219| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_send.c:217:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 215| count = send(acpt_sk, message, msg_count, flag); # 216| if (count != msg_count) # 217|-> tst_brkm(TBROK, tst_exit, "send from accept socket to client " # 218| "count:%d, errno:%d", count, errno); # 219| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:150: error[nullPointer]: Null pointer dereference: diediedie # 148| count = sendmsg(-1, &outmessage, flag); # 149| if (count != -1 || errno != EBADF) # 150|-> tst_brkm(TBROK, tst_exit, "sendmsg with a bad socket " # 151| "descriptor count:%d, errno:%d", count, errno); # 152| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:150:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 148| count = sendmsg(-1, &outmessage, flag); # 149| if (count != -1 || errno != EBADF) # 150|-> tst_brkm(TBROK, tst_exit, "sendmsg with a bad socket " # 151| "descriptor count:%d, errno:%d", count, errno); # 152| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:159: error[nullPointer]: Null pointer dereference: diediedie # 157| fd = mkstemp(filename); # 158| if (fd == -1) # 159|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 160| filename, strerror(errno)); # 161| count = sendmsg(fd, &outmessage, flag); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:159:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 157| fd = mkstemp(filename); # 158| if (fd == -1) # 159|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 160| filename, strerror(errno)); # 161| count = sendmsg(fd, &outmessage, flag); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:167: error[nullPointer]: Null pointer dereference: diediedie # 165| unlink(filename); # 166| if (count != -1 || err_no != ENOTSOCK) # 167|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid socket " # 168| "count:%d, errno:%d", count, err_no); # 169| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:167:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 165| unlink(filename); # 166| if (count != -1 || err_no != ENOTSOCK) # 167|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid socket " # 168| "count:%d, errno:%d", count, err_no); # 169| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:175: error[nullPointer]: Null pointer dereference: diediedie # 173| count = sendmsg(lstn_sk, &outmessage, flag); # 174| if (count != -1 || errno != EPIPE) # 175|-> tst_brkm(TBROK, tst_exit, "sendmsg on a listening socket " # 176| "count:%d, errno:%d", count, errno); # 177| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:175:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 173| count = sendmsg(lstn_sk, &outmessage, flag); # 174| if (count != -1 || errno != EPIPE) # 175|-> tst_brkm(TBROK, tst_exit, "sendmsg on a listening socket " # 176| "count:%d, errno:%d", count, errno); # 177| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:184: error[nullPointer]: Null pointer dereference: diediedie # 182| count = sendmsg(sk, &outmessage, flag); # 183| if (count != -1 || errno != EFAULT) # 184|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid iovec " # 185| "pointer count:%d, errno:%d", count, errno); # 186| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:184:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 182| count = sendmsg(sk, &outmessage, flag); # 183| if (count != -1 || errno != EFAULT) # 184|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid iovec " # 185| "pointer count:%d, errno:%d", count, errno); # 186| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:195: error[nullPointer]: Null pointer dereference: diediedie # 193| count = sendmsg(sk, &outmessage, flag); # 194| if (count != -1 || errno != EINVAL) # 195|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid iovec " # 196| "length count:%d, errno:%d", count, errno); # 197| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:195:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 193| count = sendmsg(sk, &outmessage, flag); # 194| if (count != -1 || errno != EINVAL) # 195|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid iovec " # 196| "length count:%d, errno:%d", count, errno); # 197| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:205: error[nullPointer]: Null pointer dereference: diediedie # 203| count = sendmsg(sk, (struct msghdr *)-1, flag); # 204| if (count != -1 || errno != EFAULT) # 205|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid msghdr " # 206| "pointer count:%d, errno:%d", count, errno); # 207| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:205:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 203| count = sendmsg(sk, (struct msghdr *)-1, flag); # 204| if (count != -1 || errno != EFAULT) # 205|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid msghdr " # 206| "pointer count:%d, errno:%d", count, errno); # 207| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:214: error[nullPointer]: Null pointer dereference: diediedie # 212| count = sendmsg(sk, &outmessage, -1); # 213| if (count != -1 || errno != EINVAL) # 214|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid sinfo " # 215| "flags count:%d, errno:%d", count, errno); # 216| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:214:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 212| count = sendmsg(sk, &outmessage, -1); # 213| if (count != -1 || errno != EINVAL) # 214|-> tst_brkm(TBROK, tst_exit, "sendmsg with invalid sinfo " # 215| "flags count:%d, errno:%d", count, errno); # 216| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:223: error[nullPointer]: Null pointer dereference: diediedie # 221| count = sendmsg(sk, &outmessage, flag); # 222| if (count != -1 || errno != EINVAL) # 223|-> tst_brkm(TBROK, tst_exit, "sendmsg with SCTP_EOF flag " # 224| "count:%d, errno:%d", count, errno); # 225| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:223:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 221| count = sendmsg(sk, &outmessage, flag); # 222| if (count != -1 || errno != EINVAL) # 223|-> tst_brkm(TBROK, tst_exit, "sendmsg with SCTP_EOF flag " # 224| "count:%d, errno:%d", count, errno); # 225| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:232: error[nullPointer]: Null pointer dereference: diediedie # 230| count = sendmsg(sk, &outmessage, flag); # 231| if (count != -1 || errno != EINVAL) # 232|-> tst_brkm(TBROK, tst_exit, "sendmsg with SCTP_ABORT flag " # 233| "count:%d, errno:%d", count, errno); # 234| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:232:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 230| count = sendmsg(sk, &outmessage, flag); # 231| if (count != -1 || errno != EINVAL) # 232|-> tst_brkm(TBROK, tst_exit, "sendmsg with SCTP_ABORT flag " # 233| "count:%d, errno:%d", count, errno); # 234| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:249: error[nullPointer]: Null pointer dereference: diediedie # 247| count = sendmsg(acpt1_sk, &outmessage, flag); # 248| if (count != -1 || errno != EPIPE) # 249|-> tst_brkm(TBROK, tst_exit, "sendmsg on a closed association " # 250| "count:%d, errno:%d", count, errno); # 251| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:249:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 247| count = sendmsg(acpt1_sk, &outmessage, flag); # 248| if (count != -1 || errno != EPIPE) # 249|-> tst_brkm(TBROK, tst_exit, "sendmsg on a closed association " # 250| "count:%d, errno:%d", count, errno); # 251| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:319: error[nullPointer]: Null pointer dereference: diediedie # 317| count = sendmsg(acpt_sk, &outmessage, flag); # 318| if (count != msg_count) # 319|-> tst_brkm(TBROK, tst_exit, "sendmsg from accept socket to " # 320| "client count:%d, errno:%d", count, errno); # 321| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:319:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 317| count = sendmsg(acpt_sk, &outmessage, flag); # 318| if (count != msg_count) # 319|-> tst_brkm(TBROK, tst_exit, "sendmsg from accept socket to " # 320| "client count:%d, errno:%d", count, errno); # 321| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:332: error[nullPointer]: Null pointer dereference: diediedie # 330| count = sendmsg(sk, &outmessage, flag); # 331| if (count != msg_count) # 332|-> tst_brkm(TBROK, tst_exit, "sendmsg from client to server " # 333| "count:%d, errno:%d", count, errno); # 334| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:332:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 330| count = sendmsg(sk, &outmessage, flag); # 331| if (count != msg_count) # 332|-> tst_brkm(TBROK, tst_exit, "sendmsg from client to server " # 333| "count:%d, errno:%d", count, errno); # 334| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:350: error[nullPointer]: Null pointer dereference: diediedie # 348| count = sendmsg(sk1, &outmessage, flag); # 349| if (count != msg_count) # 350|-> tst_brkm(TBROK, tst_exit, "sendmsg from unconnected client to " # 351| "server count:%d, errno:%d", count, errno); # 352| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:350:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 348| count = sendmsg(sk1, &outmessage, flag); # 349| if (count != msg_count) # 350|-> tst_brkm(TBROK, tst_exit, "sendmsg from unconnected client to " # 351| "server count:%d, errno:%d", count, errno); # 352| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:365: error[nullPointer]: Null pointer dereference: diediedie # 363| count = sendmsg(sk1, &outmessage, flag); # 364| if (count != msg_count) # 365|-> tst_brkm(TBROK, tst_exit, "sendmsg on a SHUT_RD socket " # 366| "count:%d, errno:%d", count, errno); # 367| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendmsg.c:365:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 363| count = sendmsg(sk1, &outmessage, flag); # 364| if (count != msg_count) # 365|-> tst_brkm(TBROK, tst_exit, "sendmsg on a SHUT_RD socket " # 366| "count:%d, errno:%d", count, errno); # 367| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendto.c:112: error[nullPointer]: Null pointer dereference: diediedie # 110| (const struct sockaddr *) &conn_addr, len); # 111| if (count != msg_count) # 112|-> tst_brkm(TBROK, tst_exit, "sendto from client to server " # 113| "count:%d, errno:%d", count, errno); # 114| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendto.c:112:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 110| (const struct sockaddr *) &conn_addr, len); # 111| if (count != msg_count) # 112|-> tst_brkm(TBROK, tst_exit, "sendto from client to server " # 113| "count:%d, errno:%d", count, errno); # 114| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendto.c:125: error[nullPointer]: Null pointer dereference: diediedie # 123| (const struct sockaddr *) &svr_addr, len); # 124| if (count != msg_count) # 125|-> tst_brkm(TBROK, tst_exit, "sendto from accept socket to client " # 126| "count:%d, errno:%d", count, errno); # 127| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendto.c:125:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 123| (const struct sockaddr *) &svr_addr, len); # 124| if (count != msg_count) # 125|-> tst_brkm(TBROK, tst_exit, "sendto from accept socket to client " # 126| "count:%d, errno:%d", count, errno); # 127| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendto.c:142: error[nullPointer]: Null pointer dereference: diediedie # 140| (const struct sockaddr *) &conn_addr, len); # 141| if (count != msg_count) # 142|-> tst_brkm(TBROK, tst_exit, "sendto from unconnected client to " # 143| "server count:%d, errno:%d", count, errno); # 144| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sendto.c:142:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 140| (const struct sockaddr *) &conn_addr, len); # 141| if (count != msg_count) # 142|-> tst_brkm(TBROK, tst_exit, "sendto from unconnected client to " # 143| "server count:%d, errno:%d", count, errno); # 144| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:111: error[nullPointer]: Null pointer dereference: diediedie # 109| error = shutdown(-1, SHUT_WR); # 110| if (error != -1 || errno != EBADF) # 111|-> tst_brkm(TBROK, tst_exit, "shutdown with a bad socket " # 112| "error:%d, errno:%d", error, errno); # 113| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:120: error[nullPointer]: Null pointer dereference: diediedie # 118| fd = mkstemp(filename); # 119| if (fd == -1) # 120|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 121| filename, strerror(errno)); # 122| error = shutdown(fd, SHUT_WR); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:128: error[nullPointer]: Null pointer dereference: diediedie # 126| unlink(filename); # 127| if (error != -1 || err_no != ENOTSOCK) # 128|-> tst_brkm(TBROK, tst_exit, "shutdown with an invalid socket " # 129| "error:%d, errno:%d", error, err_no); # 130| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:140: error[nullPointer]: Null pointer dereference: diediedie # 138| error = shutdown(clnt_sk[0], SHUT_WR); # 139| if (error < 0) # 140|-> tst_brkm(TBROK, tst_exit, "shutdown with SHUT_WR flag " # 141| "error:%d, errno:%d", error, errno); # 142| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:148: error[nullPointer]: Null pointer dereference: diediedie # 146| error = recv(acpt_sk[0], msgbuf, 100, 0); # 147| if ((error != 0) || (errno != 0)) # 148|-> tst_brkm(TBROK, tst_exit, "recv on a SHUTDOWN received socket " # 149| "error:%d, errno:%d", error, errno); # 150| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:159: error[nullPointer]: Null pointer dereference: diediedie # 157| error = recv(clnt_sk[0], msgbuf, 100, 0); # 158| if ((error != -1) || (errno != ENOTCONN)) # 159|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_WR socket with no " # 160| "messages error:%d, errno:%d", error, errno); # 161| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:171: error[nullPointer]: Null pointer dereference: diediedie # 169| error = recv(clnt_sk[1], msgbuf, 100, 0); # 170| if ((error != 0) || (errno != 0)) # 171|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RD socket " # 172| "error:%d, errno:%d", error, errno); # 173| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:177: error[nullPointer]: Null pointer dereference: diediedie # 175| error = test_send(clnt_sk[1], message, strlen(message), 0); # 176| if (error < 0) # 177|-> tst_brkm(TBROK, tst_exit, "send on a SHUT_RD socket " # 178| "error:%d, errno:%d", error, errno); # 179| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:189: error[nullPointer]: Null pointer dereference: diediedie # 187| error = recv(clnt_sk[1], msgbuf, 100, 0); # 188| if ((error != 0) || (errno != 0)) # 189|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RD socket " # 190| "error:%d, errno:%d", error, errno); # 191| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:200: error[nullPointer]: Null pointer dereference: diediedie # 198| error = recv(acpt_sk[2], msgbuf, 100, 0); # 199| if ((error != 0) || (errno != 0)) # 200|-> tst_brkm(TBROK, tst_exit, "recv on a SHUTDOWN received socket " # 201| "error:%d, errno:%d", error, errno); # 202| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:205: error[nullPointer]: Null pointer dereference: diediedie # 203| error = recv(clnt_sk[2], msgbuf, 100, 0); # 204| if ((error != 0) || (errno != 0)) # 205|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RDWR socket " # 206| "error:%d, errno:%d", error, errno); # 207| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_shutdown.c:213: error[nullPointer]: Null pointer dereference: diediedie # 211| error = shutdown(sk, SHUT_RD); # 212| if ((error != -1) || (errno != ENOTCONN)) # 213|-> tst_brkm(TBROK, tst_exit, "shutdown on an unconnected socket " # 214| "error:%d, errno:%d", error, errno); # 215| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:104: error[nullPointer]: Null pointer dereference: diediedie # 102| sk = socket(-1, SOCK_STREAM, IPPROTO_SCTP); # 103| if (sk != -1 || errno != EAFNOSUPPORT) # 104|-> tst_brkm(TBROK, tst_exit, "socket() with invalid domain " # 105| "error:%d, errno:%d", error, errno); # 106| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:104:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 102| sk = socket(-1, SOCK_STREAM, IPPROTO_SCTP); # 103| if (sk != -1 || errno != EAFNOSUPPORT) # 104|-> tst_brkm(TBROK, tst_exit, "socket() with invalid domain " # 105| "error:%d, errno:%d", error, errno); # 106| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:112: error[nullPointer]: Null pointer dereference: diediedie # 110| sk = socket(pf_class, -1, IPPROTO_SCTP); # 111| if (sk != -1 || errno != EINVAL) # 112|-> tst_brkm(TBROK, tst_exit, "socket() with invalid type " # 113| "error:%d, errno:%d", error, errno); # 114| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:112:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 110| sk = socket(pf_class, -1, IPPROTO_SCTP); # 111| if (sk != -1 || errno != EINVAL) # 112|-> tst_brkm(TBROK, tst_exit, "socket() with invalid type " # 113| "error:%d, errno:%d", error, errno); # 114| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:120: error[nullPointer]: Null pointer dereference: diediedie # 118| sk = socket(pf_class, SOCK_STREAM, IPPROTO_SCTP); # 119| if (sk < 0) # 120|-> tst_brkm(TBROK, tst_exit, "valid socket() call " # 121| "error:%d, errno:%d", error, errno); # 122| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:120:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 118| sk = socket(pf_class, SOCK_STREAM, IPPROTO_SCTP); # 119| if (sk < 0) # 120|-> tst_brkm(TBROK, tst_exit, "valid socket() call " # 121| "error:%d, errno:%d", error, errno); # 122| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:128: error[nullPointer]: Null pointer dereference: diediedie # 126| error = bind(sk, (struct sockaddr *)-1, sizeof(struct sockaddr_in)); # 127| if (error != -1 || errno != EFAULT) # 128|-> tst_brkm(TBROK, tst_exit, "bind() with invalid address ptr " # 129| "error:%d, errno:%d", error, errno); # 130| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:128:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 126| error = bind(sk, (struct sockaddr *)-1, sizeof(struct sockaddr_in)); # 127| if (error != -1 || errno != EFAULT) # 128|-> tst_brkm(TBROK, tst_exit, "bind() with invalid address ptr " # 129| "error:%d, errno:%d", error, errno); # 130| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:140: error[nullPointer]: Null pointer dereference: diediedie # 138| error = bind(sk, (struct sockaddr *) &bind_addr, sizeof(bind_addr)-2); # 139| if (error != -1 || errno != EINVAL) # 140|-> tst_brkm(TBROK, tst_exit, "bind() with invalid address length " # 141| "error:%d, errno:%d", error, errno); # 142| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:140:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 138| error = bind(sk, (struct sockaddr *) &bind_addr, sizeof(bind_addr)-2); # 139| if (error != -1 || errno != EINVAL) # 140|-> tst_brkm(TBROK, tst_exit, "bind() with invalid address length " # 141| "error:%d, errno:%d", error, errno); # 142| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:149: error[nullPointer]: Null pointer dereference: diediedie # 147| fd = mkstemp(filename); # 148| if (fd == -1) # 149|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 150| filename, strerror(errno)); # 151| error = bind(fd, (struct sockaddr *) &bind_addr, sizeof(bind_addr)); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:149:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 147| fd = mkstemp(filename); # 148| if (fd == -1) # 149|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 150| filename, strerror(errno)); # 151| error = bind(fd, (struct sockaddr *) &bind_addr, sizeof(bind_addr)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:157: error[nullPointer]: Null pointer dereference: diediedie # 155| unlink(filename); # 156| if (error != -1 || err_no != ENOTSOCK) # 157|-> tst_brkm(TBROK, tst_exit, "bind() with invalid socket " # 158| "descriptor error:%d, errno:%d", error, err_no); # 159| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:157:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 155| unlink(filename); # 156| if (error != -1 || err_no != ENOTSOCK) # 157|-> tst_brkm(TBROK, tst_exit, "bind() with invalid socket " # 158| "descriptor error:%d, errno:%d", error, err_no); # 159| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:167: error[nullPointer]: Null pointer dereference: diediedie # 165| error = bind(sk, (struct sockaddr *) &bind_addr, sizeof(bind_addr)); # 166| if (error != -1 || errno != EADDRNOTAVAIL) # 167|-> tst_brkm(TBROK, tst_exit, "bind() with invalid local " # 168| "address error:%d, errno:%d", error, errno); # 169| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:167:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 165| error = bind(sk, (struct sockaddr *) &bind_addr, sizeof(bind_addr)); # 166| if (error != -1 || errno != EADDRNOTAVAIL) # 167|-> tst_brkm(TBROK, tst_exit, "bind() with invalid local " # 168| "address error:%d, errno:%d", error, errno); # 169| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:180: error[nullPointer]: Null pointer dereference: diediedie # 178| error = bind(sk, (struct sockaddr *) &bind_addr, sizeof(bind_addr)); # 179| if (error != -1 || errno != EINVAL) # 180|-> tst_brkm(TBROK, tst_exit, "bind() on an already bound socket " # 181| "error:%d, errno:%d", error, errno); # 182| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:180:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 178| error = bind(sk, (struct sockaddr *) &bind_addr, sizeof(bind_addr)); # 179| if (error != -1 || errno != EINVAL) # 180|-> tst_brkm(TBROK, tst_exit, "bind() on an already bound socket " # 181| "error:%d, errno:%d", error, errno); # 182| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:199: error[nullPointer]: Null pointer dereference: diediedie # 197| sizeof(bind_addr)); # 198| if (error != -1 || errno != EACCES) # 199|-> tst_brkm(TBROK, tst_exit, "bind() on reserverd port " # 200| "error:%d, errno:%d", error, errno); # 201| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:199:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 197| sizeof(bind_addr)); # 198| if (error != -1 || errno != EACCES) # 199|-> tst_brkm(TBROK, tst_exit, "bind() on reserverd port " # 200| "error:%d, errno:%d", error, errno); # 201| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:211: error[nullPointer]: Null pointer dereference: diediedie # 209| error = bind(sk, (struct sockaddr *) &bind_addr,sizeof(bind_addr)); # 210| if ( error < 0 ) # 211|-> tst_brkm(TBROK, tst_exit, "bind() with INADDR_ANY address and " # 212| "non-zero port error:%d, errno:%d", error, errno); # 213| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:211:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 209| error = bind(sk, (struct sockaddr *) &bind_addr,sizeof(bind_addr)); # 210| if ( error < 0 ) # 211|-> tst_brkm(TBROK, tst_exit, "bind() with INADDR_ANY address and " # 212| "non-zero port error:%d, errno:%d", error, errno); # 213| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:228: error[nullPointer]: Null pointer dereference: diediedie # 226| error = bind(sk, (struct sockaddr *) &bind_addr,sizeof(bind_addr)); # 227| if ( error < 0 ) # 228|-> tst_brkm(TBROK, tst_exit, "bind() with INADDR_ANY address and " # 229| "zero port error:%d, errno:%d", error, errno); # 230| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:228:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 226| error = bind(sk, (struct sockaddr *) &bind_addr,sizeof(bind_addr)); # 227| if ( error < 0 ) # 228|-> tst_brkm(TBROK, tst_exit, "bind() with INADDR_ANY address and " # 229| "zero port error:%d, errno:%d", error, errno); # 230| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:246: error[nullPointer]: Null pointer dereference: diediedie # 244| error = bind(sk, (struct sockaddr *) &bind_addr,sizeof(bind_addr)); # 245| if ( error < 0 ) # 246|-> tst_brkm(TBROK, tst_exit, "bind() with local address and " # 247| "zero port error:%d, errno:%d", error, errno); # 248| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:246:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 244| error = bind(sk, (struct sockaddr *) &bind_addr,sizeof(bind_addr)); # 245| if ( error < 0 ) # 246|-> tst_brkm(TBROK, tst_exit, "bind() with local address and " # 247| "zero port error:%d, errno:%d", error, errno); # 248| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:255: error[nullPointer]: Null pointer dereference: diediedie # 253| error = listen(-1, 3); # 254| if (error != -1 || errno != EBADF) # 255|-> tst_brkm(TBROK, tst_exit, "listen() with bad socket descriptor " # 256| "error:%d, errno:%d", error, errno); # 257| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:255:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 253| error = listen(-1, 3); # 254| if (error != -1 || errno != EBADF) # 255|-> tst_brkm(TBROK, tst_exit, "listen() with bad socket descriptor " # 256| "error:%d, errno:%d", error, errno); # 257| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:264: error[nullPointer]: Null pointer dereference: diediedie # 262| fd = mkstemp(filename); # 263| if (fd == -1) # 264|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 265| filename, strerror(errno)); # 266| error = listen(fd, 3); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:264:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 262| fd = mkstemp(filename); # 263| if (fd == -1) # 264|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 265| filename, strerror(errno)); # 266| error = listen(fd, 3); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:272: error[nullPointer]: Null pointer dereference: diediedie # 270| unlink(filename); # 271| if (error != -1 || err_no != ENOTSOCK) # 272|-> tst_brkm(TBROK, tst_exit, "listen() with invalid socket " # 273| "error:%d, errno:%d", error, err_no); # 274| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:272:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 270| unlink(filename); # 271| if (error != -1 || err_no != ENOTSOCK) # 272|-> tst_brkm(TBROK, tst_exit, "listen() with invalid socket " # 273| "error:%d, errno:%d", error, err_no); # 274| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:280: error[nullPointer]: Null pointer dereference: diediedie # 278| error = listen(sk, 3); # 279| if ( error < 0 ) # 280|-> tst_brkm(TBROK, tst_exit, "listen() on a bound socket " # 281| "error:%d, errno:%d", error, errno); # 282| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_socket_bind_listen.c:280:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 278| error = listen(sk, 3); # 279| if ( error < 0 ) # 280|-> tst_brkm(TBROK, tst_exit, "listen() on a bound socket " # 281| "error:%d, errno:%d", error, errno); # 282| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:117: error[nullPointer]: Null pointer dereference: diediedie # 115| error = setsockopt(-1, IPPROTO_SCTP, 0, 0, 0); # 116| if (error != -1 || errno != EBADF) # 117|-> tst_brkm(TBROK, tst_exit, "setsockopt with a bad socket " # 118| "descriptor error:%d, errno:%d", error, errno); # 119| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:117:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 115| error = setsockopt(-1, IPPROTO_SCTP, 0, 0, 0); # 116| if (error != -1 || errno != EBADF) # 117|-> tst_brkm(TBROK, tst_exit, "setsockopt with a bad socket " # 118| "descriptor error:%d, errno:%d", error, errno); # 119| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:126: error[nullPointer]: Null pointer dereference: diediedie # 124| fd = mkstemp(filename); # 125| if (fd == -1) # 126|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 127| filename, strerror(errno)); # 128| error = setsockopt(fd, IPPROTO_SCTP, 0, 0, 0); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:126:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 124| fd = mkstemp(filename); # 125| if (fd == -1) # 126|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 127| filename, strerror(errno)); # 128| error = setsockopt(fd, IPPROTO_SCTP, 0, 0, 0); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:134: error[nullPointer]: Null pointer dereference: diediedie # 132| unlink(filename); # 133| if (error != -1 || err_no != ENOTSOCK) # 134|-> tst_brkm(TBROK, tst_exit, "setsockopt with an invalid socket " # 135| "error:%d, errno:%d", error, err_no); # 136| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:134:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 132| unlink(filename); # 133| if (error != -1 || err_no != ENOTSOCK) # 134|-> tst_brkm(TBROK, tst_exit, "setsockopt with an invalid socket " # 135| "error:%d, errno:%d", error, err_no); # 136| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:142: error[nullPointer]: Null pointer dereference: diediedie # 140| error = setsockopt(sk, -1, SCTP_RTOINFO, 0, 0); # 141| if (error != -1 || errno != ENOPROTOOPT) # 142|-> tst_brkm(TBROK, tst_exit, "setsockopt with invalid level " # 143| "error:%d, errno:%d", error, errno); # 144| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:142:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 140| error = setsockopt(sk, -1, SCTP_RTOINFO, 0, 0); # 141| if (error != -1 || errno != ENOPROTOOPT) # 142|-> tst_brkm(TBROK, tst_exit, "setsockopt with invalid level " # 143| "error:%d, errno:%d", error, errno); # 144| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:151: error[nullPointer]: Null pointer dereference: diediedie # 149| (const struct sctp_rtoinfo *)-1, sizeof(struct sctp_rtoinfo)); # 150| if (error != -1 || errno != EFAULT) # 151|-> tst_brkm(TBROK, tst_exit, "setsockopt with invalid option " # 152| "buffer error:%d, errno:%d", error, errno); # 153| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:151:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 149| (const struct sctp_rtoinfo *)-1, sizeof(struct sctp_rtoinfo)); # 150| if (error != -1 || errno != EFAULT) # 151|-> tst_brkm(TBROK, tst_exit, "setsockopt with invalid option " # 152| "buffer error:%d, errno:%d", error, errno); # 153| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:159: error[nullPointer]: Null pointer dereference: diediedie # 157| error = setsockopt(sk, IPPROTO_SCTP, SCTP_AUTOCLOSE, 0, 0); # 158| if (error != -1 || errno != EOPNOTSUPP) # 159|-> tst_brkm(TBROK, tst_exit, "setsockopt with invalid option " # 160| "name error:%d, errno:%d", error, errno); # 161| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:159:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 157| error = setsockopt(sk, IPPROTO_SCTP, SCTP_AUTOCLOSE, 0, 0); # 158| if (error != -1 || errno != EOPNOTSUPP) # 159|-> tst_brkm(TBROK, tst_exit, "setsockopt with invalid option " # 160| "name error:%d, errno:%d", error, errno); # 161| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:167: error[nullPointer]: Null pointer dereference: diediedie # 165| error = getsockopt(-1, IPPROTO_SCTP, 0, 0, 0); # 166| if (error != -1 || errno != EBADF) # 167|-> tst_brkm(TBROK, tst_exit, "getsockopt with a bad socket " # 168| "descriptor error:%d, errno:%d", error, errno); # 169| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:167:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 165| error = getsockopt(-1, IPPROTO_SCTP, 0, 0, 0); # 166| if (error != -1 || errno != EBADF) # 167|-> tst_brkm(TBROK, tst_exit, "getsockopt with a bad socket " # 168| "descriptor error:%d, errno:%d", error, errno); # 169| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:176: error[nullPointer]: Null pointer dereference: diediedie # 174| fd = mkstemp(filename); # 175| if (fd == -1) # 176|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 177| filename, strerror(errno)); # 178| error = getsockopt(fd, IPPROTO_SCTP, 0, 0, 0); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:176:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 174| fd = mkstemp(filename); # 175| if (fd == -1) # 176|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 177| filename, strerror(errno)); # 178| error = getsockopt(fd, IPPROTO_SCTP, 0, 0, 0); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:184: error[nullPointer]: Null pointer dereference: diediedie # 182| unlink(filename); # 183| if (error != -1 || err_no != ENOTSOCK) # 184|-> tst_brkm(TBROK, tst_exit, "getsockopt with an invalid socket " # 185| "error:%d, errno:%d", error, err_no); # 186| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:184:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 182| unlink(filename); # 183| if (error != -1 || err_no != ENOTSOCK) # 184|-> tst_brkm(TBROK, tst_exit, "getsockopt with an invalid socket " # 185| "error:%d, errno:%d", error, err_no); # 186| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:207: error[nullPointer]: Null pointer dereference: diediedie # 205| (struct sctp_rtoinfo *)-1, &len); # 206| if (error != -1 || errno != EFAULT) # 207|-> tst_brkm(TBROK, tst_exit, "getsockopt with invalid option " # 208| "buffer error:%d, errno:%d", error, errno); # 209| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:207:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 205| (struct sctp_rtoinfo *)-1, &len); # 206| if (error != -1 || errno != EFAULT) # 207|-> tst_brkm(TBROK, tst_exit, "getsockopt with invalid option " # 208| "buffer error:%d, errno:%d", error, errno); # 209| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:215: error[nullPointer]: Null pointer dereference: diediedie # 213| error = getsockopt(sk, IPPROTO_SCTP, SCTP_AUTOCLOSE, &grtinfo, &len); # 214| if (error != -1 || errno != EOPNOTSUPP) # 215|-> tst_brkm(TBROK, tst_exit, "getsockopt with invalid option " # 216| "name error:%d, errno:%d", error, errno); # 217| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:215:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 213| error = getsockopt(sk, IPPROTO_SCTP, SCTP_AUTOCLOSE, &grtinfo, &len); # 214| if (error != -1 || errno != EOPNOTSUPP) # 215|-> tst_brkm(TBROK, tst_exit, "getsockopt with invalid option " # 216| "name error:%d, errno:%d", error, errno); # 217| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:253: error[nullPointer]: Null pointer dereference: diediedie # 251| sinmsg.sinit_max_attempts != ginmsg.sinit_max_attempts && # 252| sinmsg.sinit_max_init_timeo != ginmsg.sinit_max_init_timeo) # 253|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SCTP_INITMSG " # 254| "compare failed"); # 255| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:253:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 251| sinmsg.sinit_max_attempts != ginmsg.sinit_max_attempts && # 252| sinmsg.sinit_max_init_timeo != ginmsg.sinit_max_init_timeo) # 253|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SCTP_INITMSG " # 254| "compare failed"); # 255| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:266: error[nullPointer]: Null pointer dereference: diediedie # 264| sinmsg.sinit_max_attempts == ginmsg.sinit_max_attempts && # 265| sinmsg.sinit_max_init_timeo == ginmsg.sinit_max_init_timeo) # 266|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SCTP_INITMSG " # 267| "unexpected compare success"); # 268| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:266:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 264| sinmsg.sinit_max_attempts == ginmsg.sinit_max_attempts && # 265| sinmsg.sinit_max_init_timeo == ginmsg.sinit_max_init_timeo) # 266|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SCTP_INITMSG " # 267| "unexpected compare success"); # 268| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:283: error[nullPointer]: Null pointer dereference: diediedie # 281| error = setsockopt(sk2, SOL_SOCKET, SO_LINGER, &slinger, len); # 282| if (error < 0) # 283|-> tst_brkm(TBROK, tst_exit, "setsockopt SO_LINGER " # 284| "error:%d, errno:%d", error, errno); # 285| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:283:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 281| error = setsockopt(sk2, SOL_SOCKET, SO_LINGER, &slinger, len); # 282| if (error < 0) # 283|-> tst_brkm(TBROK, tst_exit, "setsockopt SO_LINGER " # 284| "error:%d, errno:%d", error, errno); # 285| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:291: error[nullPointer]: Null pointer dereference: diediedie # 289| error = getsockopt(sk2, SOL_SOCKET, SO_LINGER, &glinger, &len); # 290| if (error < 0) # 291|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_LINGER " # 292| "error:%d, errno:%d", error, errno); # 293| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:291:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 289| error = getsockopt(sk2, SOL_SOCKET, SO_LINGER, &glinger, &len); # 290| if (error < 0) # 291|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_LINGER " # 292| "error:%d, errno:%d", error, errno); # 293| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:298: error[nullPointer]: Null pointer dereference: diediedie # 296| if (slinger.l_onoff != glinger.l_onoff || # 297| slinger.l_linger != glinger.l_linger) # 298|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SO_LINGER " # 299| "compare failed"); # 300| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:298:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 296| if (slinger.l_onoff != glinger.l_onoff || # 297| slinger.l_linger != glinger.l_linger) # 298|-> tst_brkm(TBROK, tst_exit, "setsockopt/getsockopt SO_LINGER " # 299| "compare failed"); # 300| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:307: error[nullPointer]: Null pointer dereference: diediedie # 305| error = getsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &rcvbuf_val_get, &len); # 306| if (error < 0) # 307|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_RCVBUF " # 308| "error:%d, errno:%d", error, errno); # 309| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:307:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 305| error = getsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &rcvbuf_val_get, &len); # 306| if (error < 0) # 307|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_RCVBUF " # 308| "error:%d, errno:%d", error, errno); # 309| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:316: error[nullPointer]: Null pointer dereference: diediedie # 314| error = getsockopt(sk2, IPPROTO_SCTP, SCTP_STATUS, &gstatus, &len); # 315| if (error < 0) # 316|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_STATUS " # 317| "error:%d, errno:%d", error, errno); # 318| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:316:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 314| error = getsockopt(sk2, IPPROTO_SCTP, SCTP_STATUS, &gstatus, &len); # 315| if (error < 0) # 316|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_STATUS " # 317| "error:%d, errno:%d", error, errno); # 318| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:328: error[nullPointer]: Null pointer dereference: diediedie # 326| error = setsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &rcvbuf_val_set, len); # 327| if (error < 0) # 328|-> tst_brkm(TBROK, tst_exit, "setsockopt SO_RCVBUF " # 329| "error:%d, errno:%d", error, errno); # 330| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:328:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 326| error = setsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &rcvbuf_val_set, len); # 327| if (error < 0) # 328|-> tst_brkm(TBROK, tst_exit, "setsockopt SO_RCVBUF " # 329| "error:%d, errno:%d", error, errno); # 330| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:335: error[nullPointer]: Null pointer dereference: diediedie # 333| error = getsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &rcvbuf_val_get, &len); # 334| if (error < 0) # 335|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_RCVBUF " # 336| "error:%d, errno:%d", error, errno); # 337| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:335:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 333| error = getsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &rcvbuf_val_get, &len); # 334| if (error < 0) # 335|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_RCVBUF " # 336| "error:%d, errno:%d", error, errno); # 337| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:339: error[nullPointer]: Null pointer dereference: diediedie # 337| # 338| if ((2 * rcvbuf_val_set) != rcvbuf_val_get) # 339|-> tst_brkm(TBROK, tst_exit, "Comparison failed:Set value and " # 340| "got value differs Set Value=%d Get Value=%d", # 341| (2*rcvbuf_val_set), rcvbuf_val_get); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:339:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 337| # 338| if ((2 * rcvbuf_val_set) != rcvbuf_val_get) # 339|-> tst_brkm(TBROK, tst_exit, "Comparison failed:Set value and " # 340| "got value differs Set Value=%d Get Value=%d", # 341| (2*rcvbuf_val_set), rcvbuf_val_get); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:347: error[nullPointer]: Null pointer dereference: diediedie # 345| error = setsockopt(sk2, SOL_SOCKET, SO_SNDBUF, &sndbuf_val_set, len); # 346| if (error < 0) # 347|-> tst_brkm(TBROK, tst_exit, "setsockopt SO_SNDBUF " # 348| "error:%d, errno:%d", error, errno); # 349| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:347:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 345| error = setsockopt(sk2, SOL_SOCKET, SO_SNDBUF, &sndbuf_val_set, len); # 346| if (error < 0) # 347|-> tst_brkm(TBROK, tst_exit, "setsockopt SO_SNDBUF " # 348| "error:%d, errno:%d", error, errno); # 349| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:355: error[nullPointer]: Null pointer dereference: diediedie # 353| error = getsockopt(sk2, SOL_SOCKET, SO_SNDBUF, &sndbuf_val_get, &len); # 354| if (error < 0) # 355|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_SNDBUF " # 356| "error:%d, errno:%d", error, errno); # 357| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:355:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 353| error = getsockopt(sk2, SOL_SOCKET, SO_SNDBUF, &sndbuf_val_get, &len); # 354| if (error < 0) # 355|-> tst_brkm(TBROK, tst_exit, "getsockopt SO_SNDBUF " # 356| "error:%d, errno:%d", error, errno); # 357| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:361: error[nullPointer]: Null pointer dereference: diediedie # 359| # 360| if ((2 * sndbuf_val_set) != sndbuf_val_get) # 361|-> tst_brkm(TBROK, tst_exit, "Comparison failed:Set value and " # 362| "got value differs Set Value=%d Get Value=%d\n", # 363| (2*sndbuf_val_set), sndbuf_val_get); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:361:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 359| # 360| if ((2 * sndbuf_val_set) != sndbuf_val_get) # 361|-> tst_brkm(TBROK, tst_exit, "Comparison failed:Set value and " # 362| "got value differs Set Value=%d Get Value=%d\n", # 363| (2*sndbuf_val_set), sndbuf_val_get); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:372: error[nullPointer]: Null pointer dereference: diediedie # 370| &len); # 371| if (error < 0) # 372|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_PRIMARY_ADDR " # 373| "error:%d, errno:%d", error, errno); # 374| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:372:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 370| &len); # 371| if (error < 0) # 372|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_PRIMARY_ADDR " # 373| "error:%d, errno:%d", error, errno); # 374| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:381: error[nullPointer]: Null pointer dereference: diediedie # 379| gaddr->sin_family != lstn_addr.sin_family && # 380| gaddr->sin_addr.s_addr != lstn_addr.sin_addr.s_addr) # 381|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_PRIMARY_ADDR value " # 382| "mismatch"); # 383| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:381:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 379| gaddr->sin_family != lstn_addr.sin_family && # 380| gaddr->sin_addr.s_addr != lstn_addr.sin_addr.s_addr) # 381|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_PRIMARY_ADDR value " # 382| "mismatch"); # 383| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:390: error[nullPointer]: Null pointer dereference: diediedie # 388| len); # 389| if (error < 0) # 390|-> tst_brkm(TBROK, tst_exit, "setsockopt SCTP_PRIMARY_ADDR " # 391| "error:%d, errno:%d", error, errno); # 392| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:390:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 388| len); # 389| if (error < 0) # 390|-> tst_brkm(TBROK, tst_exit, "setsockopt SCTP_PRIMARY_ADDR " # 391| "error:%d, errno:%d", error, errno); # 392| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:401: error[nullPointer]: Null pointer dereference: diediedie # 399| &len); # 400| if (error < 0) # 401|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_ASSOCINFO " # 402| "error:%d, errno:%d", error, errno); # 403| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:401:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 399| &len); # 400| if (error < 0) # 401|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_ASSOCINFO " # 402| "error:%d, errno:%d", error, errno); # 403| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:414: error[nullPointer]: Null pointer dereference: diediedie # 412| len); # 413| if (error < 0) # 414|-> tst_brkm(TBROK, tst_exit, "setsockopt SCTP_ASSOCINFO " # 415| "error:%d, errno:%d", error, errno); # 416| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:414:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 412| len); # 413| if (error < 0) # 414|-> tst_brkm(TBROK, tst_exit, "setsockopt SCTP_ASSOCINFO " # 415| "error:%d, errno:%d", error, errno); # 416| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:420: error[nullPointer]: Null pointer dereference: diediedie # 418| &len); # 419| if (error < 0) # 420|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_ASSOCINFO " # 421| "error:%d, errno:%d", error, errno); # 422| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:420:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 418| &len); # 419| if (error < 0) # 420|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_ASSOCINFO " # 421| "error:%d, errno:%d", error, errno); # 422| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:425: error[nullPointer]: Null pointer dereference: diediedie # 423| if (sassocparams.sasoc_asocmaxrxt != gassocparams.sasoc_asocmaxrxt || # 424| sassocparams.sasoc_cookie_life != gassocparams.sasoc_cookie_life) # 425|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_ASSOCINFO value " # 426| "mismatch"); # 427| tst_resm(TPASS, "setsockopt() SCTP_ASSOCINFO - SUCCESS"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_sockopt.c:425:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 423| if (sassocparams.sasoc_asocmaxrxt != gassocparams.sasoc_asocmaxrxt || # 424| sassocparams.sasoc_cookie_life != gassocparams.sasoc_cookie_life) # 425|-> tst_brkm(TBROK, tst_exit, "getsockopt SCTP_ASSOCINFO value " # 426| "mismatch"); # 427| tst_resm(TPASS, "setsockopt() SCTP_ASSOCINFO - SUCCESS"); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_threads.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_threads.c:177: error[nullPointer]: Null pointer dereference: diediedie # 175| status = pthread_create(&thread[cnt], &attr, relay, &pth[cnt]); # 176| if (status) # 177|-> tst_brkm(TBROK, tst_exit, "pthread_create " # 178| "failed status:%d, errno:%d", status, # 179| errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_threads.c:177:5: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 175| status = pthread_create(&thread[cnt], &attr, relay, &pth[cnt]); # 176| if (status) # 177|-> tst_brkm(TBROK, tst_exit, "pthread_create " # 178| "failed status:%d, errno:%d", status, # 179| errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_threads.c:186: error[nullPointer]: Null pointer dereference: diediedie # 184| exit_status = pthread_join (thread[cnt], &result); # 185| if (exit_status == -1) # 186|-> tst_brkm(TBROK, tst_exit, "pthread_join " # 187| "Thread #%d exited with status:%d", # 188| cnt, exit_status); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_assoc_abort.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_assoc_abort.c:207: error[nullPointer]: Null pointer dereference: diediedie # 205| &status, &status_len); # 206| if (error) # 207|-> tst_brkm(TBROK, tst_exit, # 208| "getsockopt(SCTP_STATUS): %s", # 209| strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_assoc_abort.c:221: error[nullPointer]: Null pointer dereference: diediedie # 219| &status, &status_len); # 220| if ((error != -1) && (errno != EINVAL)) # 221|-> tst_brkm(TBROK, tst_exit, # 222| "getsockopt(SCTP_STATUS) " # 223| "error:%d errno:%d", error, errno); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_assoc_shutdown.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_assoc_shutdown.c:208: error[nullPointer]: Null pointer dereference: diediedie # 206| &status, &status_len); # 207| if (error) # 208|-> tst_brkm(TBROK, tst_exit, # 209| "getsockopt(SCTP_STATUS): %s", # 210| strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_assoc_shutdown.c:222: error[nullPointer]: Null pointer dereference: diediedie # 220| &status, &status_len); # 221| if ((error != -1) && (errno != EINVAL)) # 222|-> tst_brkm(TBROK, tst_exit, # 223| "getsockopt(SCTP_STATUS) " # 224| "error:%d errno:%d", error, errno); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:154: error[nullPointer]: Null pointer dereference: diediedie # 152| error = recvmsg(sk2, &inmessage, MSG_WAITALL); # 153| if (error > 0) # 154|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket neither" # 155| "listening nor established error: %d", error); # 156| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:154:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 152| error = recvmsg(sk2, &inmessage, MSG_WAITALL); # 153| if (error > 0) # 154|-> tst_brkm(TBROK, tst_exit, "recvmsg on a socket neither" # 155| "listening nor established error: %d", error); # 156| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:161:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 159| # 160| /* Mark sk2 as being able to accept new associations. */ # 161|-> error = test_listen(sk2, 1); # 162| # 163| tst_resm(TPASS, "listen"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:200: error[nullPointer]: Null pointer dereference: diediedie # 198| # 199| if (inmessage.msg_namelen != sizeof(struct sockaddr_in6)) { # 200|-> DUMP_CORE; # 201| } # 202| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:200:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 198| # 199| if (inmessage.msg_namelen != sizeof(struct sockaddr_in6)) { # 200|-> DUMP_CORE; # 201| } # 202| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:203: error[nullPointer]: Null pointer dereference: diediedie # 201| } # 202| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { # 203|-> DUMP_CORE; # 204| } # 205| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:203:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 201| } # 202| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { # 203|-> DUMP_CORE; # 204| } # 205| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:207: error[nullPointer]: Null pointer dereference: diediedie # 205| # 206| if (msgname.v6.sin6_family != AF_INET6) { # 207|-> DUMP_CORE; # 208| } # 209| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:207:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 205| # 206| if (msgname.v6.sin6_family != AF_INET6) { # 207|-> DUMP_CORE; # 208| } # 209| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:212: error[nullPointer]: Null pointer dereference: diediedie # 210| if (memcmp(&msgname.v6.sin6_addr, &in6addr_loopback, # 211| sizeof(msgname.v6.sin6_addr))) { # 212|-> DUMP_CORE; # 213| } # 214| #else Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:212:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 210| if (memcmp(&msgname.v6.sin6_addr, &in6addr_loopback, # 211| sizeof(msgname.v6.sin6_addr))) { # 212|-> DUMP_CORE; # 213| } # 214| #else Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:216: error[nullPointer]: Null pointer dereference: diediedie # 214| #else # 215| if (inmessage.msg_namelen != sizeof(struct sockaddr_in)) { # 216|-> DUMP_CORE; # 217| } # 218| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:216:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 214| #else # 215| if (inmessage.msg_namelen != sizeof(struct sockaddr_in)) { # 216|-> DUMP_CORE; # 217| } # 218| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:219: error[nullPointer]: Null pointer dereference: diediedie # 217| } # 218| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { # 219|-> DUMP_CORE; # 220| } # 221| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:219:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 217| } # 218| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { # 219|-> DUMP_CORE; # 220| } # 221| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:223: error[nullPointer]: Null pointer dereference: diediedie # 221| # 222| if (msgname.v4.sin_family != AF_INET) { # 223|-> DUMP_CORE; # 224| } # 225| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:223:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 221| # 222| if (msgname.v4.sin_family != AF_INET) { # 223|-> DUMP_CORE; # 224| } # 225| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:226: error[nullPointer]: Null pointer dereference: diediedie # 224| } # 225| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { # 226|-> DUMP_CORE; # 227| } # 228| #endif Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:226:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 224| } # 225| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { # 226|-> DUMP_CORE; # 227| } # 228| #endif Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:256: error[nullPointer]: Null pointer dereference: diediedie # 254| # 255| if (inmessage.msg_namelen != sizeof(struct sockaddr_in6)) { # 256|-> DUMP_CORE; # 257| } # 258| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:256:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 254| # 255| if (inmessage.msg_namelen != sizeof(struct sockaddr_in6)) { # 256|-> DUMP_CORE; # 257| } # 258| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:259: error[nullPointer]: Null pointer dereference: diediedie # 257| } # 258| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { # 259|-> DUMP_CORE; # 260| } # 261| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:259:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 257| } # 258| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { # 259|-> DUMP_CORE; # 260| } # 261| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:263: error[nullPointer]: Null pointer dereference: diediedie # 261| # 262| if (msgname.v6.sin6_family != AF_INET6) { # 263|-> DUMP_CORE; # 264| } # 265| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:268: error[nullPointer]: Null pointer dereference: diediedie # 266| if (memcmp(&msgname.v6.sin6_addr, &in6addr_loopback, # 267| sizeof(msgname.v6.sin6_addr))) { # 268|-> DUMP_CORE; # 269| } # 270| #else Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:272: error[nullPointer]: Null pointer dereference: diediedie # 270| #else # 271| if (inmessage.msg_namelen != sizeof(struct sockaddr_in)) { # 272|-> DUMP_CORE; # 273| } # 274| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:272:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 270| #else # 271| if (inmessage.msg_namelen != sizeof(struct sockaddr_in)) { # 272|-> DUMP_CORE; # 273| } # 274| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:275: error[nullPointer]: Null pointer dereference: diediedie # 273| } # 274| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { # 275|-> DUMP_CORE; # 276| } # 277| if (msgname.v4.sin_family != AF_INET) { Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:275:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 273| } # 274| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { # 275|-> DUMP_CORE; # 276| } # 277| if (msgname.v4.sin_family != AF_INET) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:278: error[nullPointer]: Null pointer dereference: diediedie # 276| } # 277| if (msgname.v4.sin_family != AF_INET) { # 278|-> DUMP_CORE; # 279| } # 280| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:281: error[nullPointer]: Null pointer dereference: diediedie # 279| } # 280| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { # 281|-> DUMP_CORE; # 282| } # 283| #endif Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:305: error[nullPointer]: Null pointer dereference: diediedie # 303| bytes_sent = sendmsg(sk1, &outmessage, MSG_NOSIGNAL); # 304| if ((bytes_sent > 0) || (EPIPE != errno)) # 305|-> tst_brkm(TBROK, tst_exit, "sendmsg with NULL associd and " # 306| "NULL msg_name error:%d errno:%d", error, errno); # 307| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:314: error[nullPointer]: Null pointer dereference: diediedie # 312| bytes_sent = sendmsg(sk1, &outmessage, MSG_NOSIGNAL); # 313| if ((bytes_sent > 0) || (EPIPE != errno)) # 314|-> tst_brkm(TBROK, tst_exit, "sendmsg with incorrect associd " # 315| "error:%d errno:%d", error, errno); # 316| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:347: error[nullPointer]: Null pointer dereference: diediedie # 345| n_laddrs = sctp_getladdrs(sk1, associd1, &laddrs); # 346| if (n_laddrs <= 0) # 347|-> tst_brkm(TBROK, tst_exit, "sctp_getladdrs: %s", # 348| strerror(errno)); # 349| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:377: error[nullPointer]: Null pointer dereference: diediedie # 375| n_paddrs = sctp_getpaddrs(sk1, associd1, &paddrs); # 376| if (n_paddrs <= 0) # 377|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs: %s", # 378| strerror(errno)); # 379| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:419: error[nullPointer]: Null pointer dereference: diediedie # 417| # 418| if (inmessage.msg_namelen != sizeof(struct sockaddr_in6)) { # 419|-> DUMP_CORE; # 420| } # 421| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:422: error[nullPointer]: Null pointer dereference: diediedie # 420| } # 421| if (msgname.v6.sin6_port != htons(SCTP_TESTPORT_1)) { # 422|-> DUMP_CORE; # 423| } # 424| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:426: error[nullPointer]: Null pointer dereference: diediedie # 424| # 425| if (msgname.v6.sin6_family != AF_INET6) { # 426|-> DUMP_CORE; # 427| } # 428| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:431: error[nullPointer]: Null pointer dereference: diediedie # 429| if (memcmp(&msgname.v6.sin6_addr, &in6addr_loopback, # 430| sizeof(msgname.v6.sin6_addr))) { # 431|-> DUMP_CORE; # 432| } # 433| #else Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:435: error[nullPointer]: Null pointer dereference: diediedie # 433| #else # 434| if (inmessage.msg_namelen != sizeof(struct sockaddr_in)) { # 435|-> DUMP_CORE; # 436| } # 437| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:438: error[nullPointer]: Null pointer dereference: diediedie # 436| } # 437| if (msgname.v4.sin_port != htons(SCTP_TESTPORT_1)) { # 438|-> DUMP_CORE; # 439| } # 440| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:442: error[nullPointer]: Null pointer dereference: diediedie # 440| # 441| if (msgname.v4.sin_family != AF_INET) { # 442|-> DUMP_CORE; # 443| } # 444| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_basic.c:445: error[nullPointer]: Null pointer dereference: diediedie # 443| } # 444| if (msgname.v4.sin_addr.s_addr != SCTP_IP_LOOPBACK) { # 445|-> DUMP_CORE; # 446| } # 447| #endif Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:110: error[nullPointer]: Null pointer dereference: diediedie # 108| flags = fcntl(clt_sk1, F_GETFL, 0); # 109| if (flags < 0) # 110|-> tst_brkm(TBROK, tst_exit, "fcntl F_GETFL: %s", strerror(errno)); # 111| if (fcntl(clt_sk1, F_SETFL, flags | O_NONBLOCK) < 0) # 112| tst_brkm(TBROK, tst_exit, "fcntl F_SETFL: %s", strerror(errno)); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:110:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 108| flags = fcntl(clt_sk1, F_GETFL, 0); # 109| if (flags < 0) # 110|-> tst_brkm(TBROK, tst_exit, "fcntl F_GETFL: %s", strerror(errno)); # 111| if (fcntl(clt_sk1, F_SETFL, flags | O_NONBLOCK) < 0) # 112| tst_brkm(TBROK, tst_exit, "fcntl F_SETFL: %s", strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:112: error[nullPointer]: Null pointer dereference: diediedie # 110| tst_brkm(TBROK, tst_exit, "fcntl F_GETFL: %s", strerror(errno)); # 111| if (fcntl(clt_sk1, F_SETFL, flags | O_NONBLOCK) < 0) # 112|-> tst_brkm(TBROK, tst_exit, "fcntl F_SETFL: %s", strerror(errno)); # 113| # 114| /* Do a non-blocking connect from clt_sk1 to svr_sk */ Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:112:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 110| tst_brkm(TBROK, tst_exit, "fcntl F_GETFL: %s", strerror(errno)); # 111| if (fcntl(clt_sk1, F_SETFL, flags | O_NONBLOCK) < 0) # 112|-> tst_brkm(TBROK, tst_exit, "fcntl F_SETFL: %s", strerror(errno)); # 113| # 114| /* Do a non-blocking connect from clt_sk1 to svr_sk */ Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:118: error[nullPointer]: Null pointer dereference: diediedie # 116| /* Non-blocking connect should return immediately with EINPROGRESS. */ # 117| if ((error != -1) || (EINPROGRESS != errno)) # 118|-> tst_brkm(TBROK, tst_exit, "non-blocking connect error: %d" # 119| "errno:%d", error, errno); # 120| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:118:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 116| /* Non-blocking connect should return immediately with EINPROGRESS. */ # 117| if ((error != -1) || (EINPROGRESS != errno)) # 118|-> tst_brkm(TBROK, tst_exit, "non-blocking connect error: %d" # 119| "errno:%d", error, errno); # 120| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:128: error[nullPointer]: Null pointer dereference: diediedie # 126| error = connect(clt_sk1, &svr_loop.sa, sizeof(svr_loop)); # 127| if ((error != -1) || (EISCONN != errno)) # 128|-> tst_brkm(TBROK, tst_exit, "connect on a socket to create an " # 129| "assoc that is already established error:%d errno:%d", # 130| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:128:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 126| error = connect(clt_sk1, &svr_loop.sa, sizeof(svr_loop)); # 127| if ((error != -1) || (EISCONN != errno)) # 128|-> tst_brkm(TBROK, tst_exit, "connect on a socket to create an " # 129| "assoc that is already established error:%d errno:%d", # 130| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:195: error[nullPointer]: Null pointer dereference: diediedie # 193| error = connect(peeloff_sk, &clt_loop3.sa, sizeof(clt_loop3)); # 194| if ((error != -1) || (EISCONN != errno)) # 195|-> tst_brkm(TBROK, tst_exit, "connect on a peeled off socket " # 196| "error:%d, errno:%d", error, errno); # 197| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:195:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 193| error = connect(peeloff_sk, &clt_loop3.sa, sizeof(clt_loop3)); # 194| if ((error != -1) || (EISCONN != errno)) # 195|-> tst_brkm(TBROK, tst_exit, "connect on a peeled off socket " # 196| "error:%d, errno:%d", error, errno); # 197| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:205: error[nullPointer]: Null pointer dereference: diediedie # 203| error = connect(svr_sk, &clt_loop1.sa, sizeof(clt_loop1)); # 204| if ((error != -1) || (EADDRNOTAVAIL != errno)) # 205|-> tst_brkm(TBROK, tst_exit, "connect to create an assoc that " # 206| "matches a peeled off assoc error:%d errno:%d", # 207| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connect.c:205:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 203| error = connect(svr_sk, &clt_loop1.sa, sizeof(clt_loop1)); # 204| if ((error != -1) || (EADDRNOTAVAIL != errno)) # 205|-> tst_brkm(TBROK, tst_exit, "connect to create an assoc that " # 206| "matches a peeled off assoc error:%d errno:%d", # 207| error, errno); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:146: error[nullPointer]: Null pointer dereference: diediedie # 144| flags = fcntl(clt_sk1, F_GETFL, 0); # 145| if (flags < 0) # 146|-> tst_brkm(TBROK, tst_exit, "fcntl F_GETFL: %s", strerror(errno)); # 147| if (fcntl(clt_sk1, F_SETFL, flags | O_NONBLOCK) < 0) # 148| tst_brkm(TBROK, tst_exit, "fcntl F_SETFL: %s", strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:148: error[nullPointer]: Null pointer dereference: diediedie # 146| tst_brkm(TBROK, tst_exit, "fcntl F_GETFL: %s", strerror(errno)); # 147| if (fcntl(clt_sk1, F_SETFL, flags | O_NONBLOCK) < 0) # 148|-> tst_brkm(TBROK, tst_exit, "fcntl F_SETFL: %s", strerror(errno)); # 149| # 150| /* Do a non-blocking connectx from clt_sk1 to svr_sk */ Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:155: error[nullPointer]: Null pointer dereference: diediedie # 153| /* Non-blocking connectx should return immediately with EINPROGRESS. */ # 154| if ((error != -1) || (EINPROGRESS != errno)) # 155|-> tst_brkm(TBROK, tst_exit, "non-blocking connectx error: %d" # 156| "errno:%d", error, errno); # 157| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:166: error[nullPointer]: Null pointer dereference: diediedie # 164| NULL); # 165| if ((error != -1) || (EISCONN != errno)) # 166|-> tst_brkm(TBROK, tst_exit, "connectx on a socket to create an " # 167| "assoc that is already established error:%d errno:%d", # 168| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:192: error[nullPointer]: Null pointer dereference: diediedie # 190| if (associd) { # 191| if (associd != clt_associd1) # 192|-> tst_brkm(TBROK, tst_exit, "Association id mismatch: " # 193| "connectx returned %d, notification returned:%d", # 194| associd, clt_associd1); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:237: error[nullPointer]: Null pointer dereference: diediedie # 235| NULL); # 236| if ((error != -1) || (EISCONN != errno)) # 237|-> tst_brkm(TBROK, tst_exit, "connectx on a peeled off socket " # 238| "error:%d, errno:%d", error, errno); # 239| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_connectx.c:248: error[nullPointer]: Null pointer dereference: diediedie # 246| NULL); # 247| if ((error != -1) || (EADDRNOTAVAIL != errno)) # 248|-> tst_brkm(TBROK, tst_exit, "connectx to create an assoc that " # 249| "matches a peeled off assoc error:%d errno:%d", # 250| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_fragments.c:215: error[nullPointer]: Null pointer dereference: diediedie # 213| &optlen); # 214| if ((error != 0) && (disable_frag != 1)) # 215|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DISABLE_FRAGMENTS) " # 216| "error:%d errno:%d disable_frag:%d", # 217| error, errno, disable_frag); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_fragments.c:230: error[nullPointer]: Null pointer dereference: diediedie # 228| error = sendmsg(sk1, &outmessage, 0); # 229| if ((error != -1) || (errno != EMSGSIZE)) # 230|-> tst_brkm(TBROK, tst_exit, "Send a message that exceeds " # 231| "assoc frag point error:%d errno:%d", error, errno); # 232| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_fragments.c:230:10: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 228| error = sendmsg(sk1, &outmessage, 0); # 229| if ((error != -1) || (errno != EMSGSIZE)) # 230|-> tst_brkm(TBROK, tst_exit, "Send a message that exceeds " # 231| "assoc frag point error:%d errno:%d", error, errno); # 232| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:99: error[nullPointer]: Null pointer dereference: diediedie # 97| error = getsockname(svr_sk, (struct sockaddr *)&svr_local_addr, &len); # 98| if (0 != error) # 99|-> tst_brkm(TBROK, tst_exit, "getsockname: %s", strerror(errno)); # 100| # 101| tst_resm(TPASS, "getsockname on an unconnected socket"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:99:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 97| error = getsockname(svr_sk, (struct sockaddr *)&svr_local_addr, &len); # 98| if (0 != error) # 99|-> tst_brkm(TBROK, tst_exit, "getsockname: %s", strerror(errno)); # 100| # 101| tst_resm(TPASS, "getsockname on an unconnected socket"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:108: error[nullPointer]: Null pointer dereference: diediedie # 106| error = getpeername(svr_sk, (struct sockaddr *)&svr_peer_addr, &len); # 107| if ((-1 != error) || (ENOTCONN != errno)) # 108|-> tst_brkm(TBROK, tst_exit, "getpeername on an unconnected " # 109| "socket error:%d, errno:%d", error, errno); # 110| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:108:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 106| error = getpeername(svr_sk, (struct sockaddr *)&svr_peer_addr, &len); # 107| if ((-1 != error) || (ENOTCONN != errno)) # 108|-> tst_brkm(TBROK, tst_exit, "getpeername on an unconnected " # 109| "socket error:%d, errno:%d", error, errno); # 110| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:132: error[nullPointer]: Null pointer dereference: diediedie # 130| error = getsockname(clt_sk, (struct sockaddr *)&clt_local_addr, &len); # 131| if (0 != error) # 132|-> tst_brkm(TBROK, tst_exit, "getsockname on a connected client " # 133| "socket: %s", strerror(errno)); # 134| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:132:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 130| error = getsockname(clt_sk, (struct sockaddr *)&clt_local_addr, &len); # 131| if (0 != error) # 132|-> tst_brkm(TBROK, tst_exit, "getsockname on a connected client " # 133| "socket: %s", strerror(errno)); # 134| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:142: error[nullPointer]: Null pointer dereference: diediedie # 140| error = getpeername(clt_sk, (struct sockaddr *)&clt_peer_addr, &len); # 141| if (0 != error) # 142|-> tst_brkm(TBROK, tst_exit, "getpeername on a connected client " # 143| "socket: %s", strerror(errno)); # 144| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:142:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 140| error = getpeername(clt_sk, (struct sockaddr *)&clt_peer_addr, &len); # 141| if (0 != error) # 142|-> tst_brkm(TBROK, tst_exit, "getpeername on a connected client " # 143| "socket: %s", strerror(errno)); # 144| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:157: error[nullPointer]: Null pointer dereference: diediedie # 155| &len); # 156| if (0 != error) # 157|-> tst_brkm(TBROK, tst_exit, "getsockname on a connected server " # 158| "socket: %s", strerror(errno)); # 159| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:157:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 155| &len); # 156| if (0 != error) # 157|-> tst_brkm(TBROK, tst_exit, "getsockname on a connected server " # 158| "socket: %s", strerror(errno)); # 159| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:168: error[nullPointer]: Null pointer dereference: diediedie # 166| &len); # 167| if (0 != error) # 168|-> tst_brkm(TBROK, tst_exit, "getpeername on a connected server " # 169| "socket: %s", strerror(errno)); # 170| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:168:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 166| &len); # 167| if (0 != error) # 168|-> tst_brkm(TBROK, tst_exit, "getpeername on a connected server " # 169| "socket: %s", strerror(errno)); # 170| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:174: error[nullPointer]: Null pointer dereference: diediedie # 172| # 173| if (svr_local_addr.v4.sin_port != clt_peer_addr.v4.sin_port) # 174|-> tst_brkm(TBROK, tst_exit, "Server's local port(%d) doesn't " # 175| "match Client's peer port(%d)\n", # 176| svr_local_addr.v4.sin_port, clt_peer_addr.v4.sin_port); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:174:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 172| # 173| if (svr_local_addr.v4.sin_port != clt_peer_addr.v4.sin_port) # 174|-> tst_brkm(TBROK, tst_exit, "Server's local port(%d) doesn't " # 175| "match Client's peer port(%d)\n", # 176| svr_local_addr.v4.sin_port, clt_peer_addr.v4.sin_port); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:179: error[nullPointer]: Null pointer dereference: diediedie # 177| # 178| if (svr_peer_addr.v4.sin_port != clt_local_addr.v4.sin_port) # 179|-> tst_brkm(TBROK, tst_exit, "Server's peer port(%d) doesn't " # 180| "match Client's local port(%d)\n", # 181| svr_peer_addr.v4.sin_port, clt_local_addr.v4.sin_port); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:179:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 177| # 178| if (svr_peer_addr.v4.sin_port != clt_local_addr.v4.sin_port) # 179|-> tst_brkm(TBROK, tst_exit, "Server's peer port(%d) doesn't " # 180| "match Client's local port(%d)\n", # 181| svr_peer_addr.v4.sin_port, clt_local_addr.v4.sin_port); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:184: error[nullPointer]: Null pointer dereference: diediedie # 182| #if TEST_V6 # 183| if (memcmp(&svr_local_addr, &clt_peer_addr, len) != 0) # 184|-> tst_brkm(TBROK, tst_exit, "Server's local address and client's " # 185| "peer addresses do not match\n"); # 186| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:184:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 182| #if TEST_V6 # 183| if (memcmp(&svr_local_addr, &clt_peer_addr, len) != 0) # 184|-> tst_brkm(TBROK, tst_exit, "Server's local address and client's " # 185| "peer addresses do not match\n"); # 186| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:188: error[nullPointer]: Null pointer dereference: diediedie # 186| # 187| if (memcmp(&svr_peer_addr, &clt_local_addr, len) != 0) # 188|-> tst_brkm(TBROK, tst_exit, "Server's peer address and client's " # 189| "local addresses do not match\n"); # 190| #else Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:188:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 186| # 187| if (memcmp(&svr_peer_addr, &clt_local_addr, len) != 0) # 188|-> tst_brkm(TBROK, tst_exit, "Server's peer address and client's " # 189| "local addresses do not match\n"); # 190| #else Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:193: error[nullPointer]: Null pointer dereference: diediedie # 191| if (svr_local_addr.v4.sin_addr.s_addr != # 192| clt_peer_addr.v4.sin_addr.s_addr) # 193|-> tst_brkm(TBROK, tst_exit, "Server's local address and client's " # 194| "peer addresses do not match\n"); # 195| if (svr_peer_addr.v4.sin_addr.s_addr != Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:193:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 191| if (svr_local_addr.v4.sin_addr.s_addr != # 192| clt_peer_addr.v4.sin_addr.s_addr) # 193|-> tst_brkm(TBROK, tst_exit, "Server's local address and client's " # 194| "peer addresses do not match\n"); # 195| if (svr_peer_addr.v4.sin_addr.s_addr != Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:197: error[nullPointer]: Null pointer dereference: diediedie # 195| if (svr_peer_addr.v4.sin_addr.s_addr != # 196| clt_local_addr.v4.sin_addr.s_addr) # 197|-> tst_brkm(TBROK, tst_exit, "Server's peer address and client's " # 198| "local addresses do not match\n"); # 199| #endif Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:197:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 195| if (svr_peer_addr.v4.sin_addr.s_addr != # 196| clt_local_addr.v4.sin_addr.s_addr) # 197|-> tst_brkm(TBROK, tst_exit, "Server's peer address and client's " # 198| "local addresses do not match\n"); # 199| #endif Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:207: error[nullPointer]: Null pointer dereference: diediedie # 205| error = getsockname(-1, (struct sockaddr *)&clt_local_addr, &len); # 206| if (error != -1 || errno != EBADF) # 207|-> tst_brkm(TBROK, tst_exit, "getsockname on a bad socket " # 208| "descriptor. error:%d errno:%d", error, errno); # 209| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:207:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 205| error = getsockname(-1, (struct sockaddr *)&clt_local_addr, &len); # 206| if (error != -1 || errno != EBADF) # 207|-> tst_brkm(TBROK, tst_exit, "getsockname on a bad socket " # 208| "descriptor. error:%d errno:%d", error, errno); # 209| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:216: error[nullPointer]: Null pointer dereference: diediedie # 214| fd = mkstemp(filename); # 215| if (fd == -1) # 216|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 217| filename, strerror(errno)); # 218| error = getsockname(fd, (struct sockaddr *)&clt_local_addr, &len); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:216:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 214| fd = mkstemp(filename); # 215| if (fd == -1) # 216|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 217| filename, strerror(errno)); # 218| error = getsockname(fd, (struct sockaddr *)&clt_local_addr, &len); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:224: error[nullPointer]: Null pointer dereference: diediedie # 222| unlink(filename); # 223| if (error != -1 || err_no != ENOTSOCK) # 224|-> tst_brkm(TBROK, tst_exit, "getsockname on an invalid socket " # 225| "error:%d errno:%d", error, err_no); # 226| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:224:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 222| unlink(filename); # 223| if (error != -1 || err_no != ENOTSOCK) # 224|-> tst_brkm(TBROK, tst_exit, "getsockname on an invalid socket " # 225| "error:%d errno:%d", error, err_no); # 226| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:232: error[nullPointer]: Null pointer dereference: diediedie # 230| error = getsockname(clt_sk, (struct sockaddr *)-1, &len); # 231| if (error != -1 || errno != EFAULT) # 232|-> tst_brkm(TBROK, tst_exit, "getsockname with invalid buffer " # 233| "error:%d errno:%d", error, errno); # 234| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:232:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 230| error = getsockname(clt_sk, (struct sockaddr *)-1, &len); # 231| if (error != -1 || errno != EFAULT) # 232|-> tst_brkm(TBROK, tst_exit, "getsockname with invalid buffer " # 233| "error:%d errno:%d", error, errno); # 234| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:242: error[nullPointer]: Null pointer dereference: diediedie # 240| error = getpeername(-1, (struct sockaddr *)&clt_local_addr, &len); # 241| if (error != -1 || errno != EBADF) # 242|-> tst_brkm(TBROK, tst_exit, "getpeername on a bad socket " # 243| "descriptor. error:%d errno:%d", error, errno); # 244| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:242:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 240| error = getpeername(-1, (struct sockaddr *)&clt_local_addr, &len); # 241| if (error != -1 || errno != EBADF) # 242|-> tst_brkm(TBROK, tst_exit, "getpeername on a bad socket " # 243| "descriptor. error:%d errno:%d", error, errno); # 244| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:251: error[nullPointer]: Null pointer dereference: diediedie # 249| fd = mkstemp(filename); # 250| if (fd == -1) # 251|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 252| filename, strerror(errno)); # 253| error = getpeername(fd, (struct sockaddr *)&clt_local_addr, &len); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:251:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 249| fd = mkstemp(filename); # 250| if (fd == -1) # 251|-> tst_brkm(TBROK, tst_exit, "Failed to mkstemp %s: %s", # 252| filename, strerror(errno)); # 253| error = getpeername(fd, (struct sockaddr *)&clt_local_addr, &len); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:259: error[nullPointer]: Null pointer dereference: diediedie # 257| unlink(filename); # 258| if (error != -1 || err_no != ENOTSOCK) # 259|-> tst_brkm(TBROK, tst_exit, "getpeername on an invalid socket " # 260| "error:%d errno:%d", error, err_no); # 261| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:259:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 257| unlink(filename); # 258| if (error != -1 || err_no != ENOTSOCK) # 259|-> tst_brkm(TBROK, tst_exit, "getpeername on an invalid socket " # 260| "error:%d errno:%d", error, err_no); # 261| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:267: error[nullPointer]: Null pointer dereference: diediedie # 265| error = getpeername(clt_sk, (struct sockaddr *)-1, &len); # 266| if (error != -1 || errno != EFAULT) # 267|-> tst_brkm(TBROK, tst_exit, "getpeername with invalid buffer " # 268| "error:%d errno:%d", error, errno); # 269| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:267:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 265| error = getpeername(clt_sk, (struct sockaddr *)-1, &len); # 266| if (error != -1 || errno != EFAULT) # 267|-> tst_brkm(TBROK, tst_exit, "getpeername with invalid buffer " # 268| "error:%d errno:%d", error, errno); # 269| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_inaddr_any.c:136: error[nullPointer]: Null pointer dereference: diediedie # 134| error = getsockname(sk1, &loop.sa, &namelen); # 135| if (error != 0) # 136|-> tst_brkm(TBROK, tst_exit, "getsockname: %s", strerror(errno)); # 137| # 138| namelen = sizeof(anyaddr); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_inaddr_any.c:136:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 134| error = getsockname(sk1, &loop.sa, &namelen); # 135| if (error != 0) # 136|-> tst_brkm(TBROK, tst_exit, "getsockname: %s", strerror(errno)); # 137| # 138| namelen = sizeof(anyaddr); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_inaddr_any.c:141: error[nullPointer]: Null pointer dereference: diediedie # 139| error = getsockname(sk2, &anyaddr.sa, &namelen); # 140| if (error != 0) # 141|-> tst_brkm(TBROK, tst_exit, "getsockname: %s", strerror(errno)); # 142| # 143| #if TEST_V6 Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_inaddr_any.c:141:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 139| error = getsockname(sk2, &anyaddr.sa, &namelen); # 140| if (error != 0) # 141|-> tst_brkm(TBROK, tst_exit, "getsockname: %s", strerror(errno)); # 142| # 143| #if TEST_V6 Error: CPPCHECK_WARNING (CWE-401): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_inaddr_any.c:250: error[memleak]: Memory leak: iov.iov_base # 248| # 249| /* Indicate successful completion. */ # 250|-> return 0; # 251| } Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_peeloff.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_peeloff.c:207: error[nullPointer]: Null pointer dereference: diediedie # 205| error = listen(peeloff_sk[0], 1); # 206| if (error != -1) # 207|-> tst_brkm(TBROK, tst_exit, "listen on a peeled off socket " # 208| "error: %d, errno: %d", error, errno); # 209| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_peeloff.c:218: error[nullPointer]: Null pointer dereference: diediedie # 216| if ((-1 != sctp_peeloff(peeloff_sk[0], svr_associd[0])) || # 217| (EINVAL != errno)) # 218|-> tst_brkm(TBROK, tst_exit, "sctp_peeloff on a peeled off " # 219| "socket error:%d, errno:%d", # 220| error, errno); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:150: error[nullPointer]: Null pointer dereference: diediedie # 148| # 149| if (error) # 150|-> tst_brkm(TBROK, tst_exit, "can't get rcvbuf size: %s", # 151| strerror(errno)); # 152| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:150:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 148| # 149| if (error) # 150|-> tst_brkm(TBROK, tst_exit, "can't get rcvbuf size: %s", # 151| strerror(errno)); # 152| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:157: error[nullPointer]: Null pointer dereference: diediedie # 155| error = setsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &len, sizeof(len)); # 156| if (error) # 157|-> tst_brkm(TBROK, tst_exit, "setsockopt(SO_RCVBUF): %s", # 158| strerror(errno)); # 159| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:157:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 155| error = setsockopt(sk2, SOL_SOCKET, SO_RCVBUF, &len, sizeof(len)); # 156| if (error) # 157|-> tst_brkm(TBROK, tst_exit, "setsockopt(SO_RCVBUF): %s", # 158| strerror(errno)); # 159| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:221: error[nullPointer]: Null pointer dereference: diediedie # 219| # 220| if (error) # 221|-> tst_brkm(TBROK, tst_exit, "can't get rwnd size: %s", # 222| strerror(errno)); # 223| tst_resm(TINFO, "creating a fillmsg of size %d", Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:221:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 219| # 220| if (error) # 221|-> tst_brkm(TBROK, tst_exit, "can't get rwnd size: %s", # 222| strerror(errno)); # 223| tst_resm(TINFO, "creating a fillmsg of size %d", Error: GCC_ANALYZER_WARNING (CWE-688): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:228:9: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘fillmsg’ where non-null expected lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:223:9: note: in expansion of macro ‘tst_resm’ <built-in>: note: argument 1 of ‘__builtin_memset’ must be non-null # 226| # 227| /* Send a fillmsg */ # 228|-> memset(fillmsg, 'X', gstatus.sstat_rwnd+RWND_SLOP); # 229| fillmsg[gstatus.sstat_rwnd+RWND_SLOP-1] = '\0'; # 230| ppid++; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:283: error[nullPointer]: Null pointer dereference: diediedie # 281| strlen(nottlmsg) + 1, MSG_EOR, stream, ppid); # 282| if (0 != strncmp(big_buffer, nottlmsg, strlen(nottlmsg))) # 283|-> tst_brkm(TBROK, tst_exit, "sctp_recvmsg: Wrong Message !!!"); # 284| # 285| tst_resm(TPASS, "sctp_recvmsg msg with zero ttl"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:283:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 281| strlen(nottlmsg) + 1, MSG_EOR, stream, ppid); # 282| if (0 != strncmp(big_buffer, nottlmsg, strlen(nottlmsg))) # 283|-> tst_brkm(TBROK, tst_exit, "sctp_recvmsg: Wrong Message !!!"); # 284| # 285| tst_resm(TPASS, "sctp_recvmsg msg with zero ttl"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:302: error[nullPointer]: Null pointer dereference: diediedie # 300| ssf = (struct sctp_send_failed *)big_buffer; # 301| if (0 != strncmp(ttlmsg, (char *)ssf->ssf_data, strlen(ttlmsg) + 1)) # 302|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 303| # 304| tst_resm(TPASS, "sctp_recvmsg SEND_FAILED for message with ttl"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:302:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 300| ssf = (struct sctp_send_failed *)big_buffer; # 301| if (0 != strncmp(ttlmsg, (char *)ssf->ssf_data, strlen(ttlmsg) + 1)) # 302|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 303| # 304| tst_resm(TPASS, "sctp_recvmsg SEND_FAILED for message with ttl"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:325: error[nullPointer]: Null pointer dereference: diediedie # 323| if (0 != strncmp(&ttlfrag[offset], (char *)ssf->ssf_data, # 324| SMALL_MAXSEG)) # 325|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 326| offset += SMALL_MAXSEG; # 327| } while (!(ssf->ssf_info.sinfo_flags & 0x01)); /* LAST FRAG */ Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendrecvmsg.c:325:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 323| if (0 != strncmp(&ttlfrag[offset], (char *)ssf->ssf_data, # 324| SMALL_MAXSEG)) # 325|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 326| offset += SMALL_MAXSEG; # 327| } while (!(ssf->ssf_info.sinfo_flags & 0x01)); /* LAST FRAG */ Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:209:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 207| rn_len = sizeof(rn); # 208| # 209|-> error = test_sctp_recvv(sk2, &iov, 1, (struct sockaddr *)&msgname, # 210| &msgname_len, &rn, &rn_len, &infotype, # 211| &msg_flags); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:213: error[nullPointer]: Null pointer dereference: diediedie # 211| &msg_flags); # 212| if (infotype != SCTP_RECVV_NOINFO) # 213|-> tst_brkm(TBROK, tst_exit, "sctp_recvv infotype %d != %d", # 214| infotype, SCTP_RECVV_NOINFO); # 215| tst_resm(TPASS, "sctp_recvv SCTP_RECVV_NOINFO"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:220: error[nullPointer]: Null pointer dereference: diediedie # 218| &val, sizeof(val)); # 219| if (error) # 220|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_RECVRCVINFO): %s", # 221| strerror(errno)); # 222| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:223:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 221| strerror(errno)); # 222| # 223|-> error = test_sctp_recvv(sk2, &iov, 1, (struct sockaddr *)&msgname, # 224| &msgname_len, &rn, &rn_len, &infotype, # 225| &msg_flags); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:228: error[nullPointer]: Null pointer dereference: diediedie # 226| if (infotype != SCTP_RECVV_RCVINFO || # 227| rn.recvv_rcvinfo.rcv_sid != 1) # 228|-> tst_brkm(TBROK, tst_exit, "sctp_recvv infotype %d != %d", # 229| infotype, SCTP_RECVV_NOINFO); # 230| tst_resm(TPASS, "sctp_recvv SCTP_RECVV_RCVINFO"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:235: error[nullPointer]: Null pointer dereference: diediedie # 233| &val, sizeof(val)); # 234| if (error) # 235|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_RECVNXTINFO): %s", # 236| strerror(errno)); # 237| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:239:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 237| # 238| rn_len = 1; # 239|-> error = test_sctp_recvv(sk2, &iov, 1, (struct sockaddr *)&msgname, # 240| &msgname_len, &rn, &rn_len, &infotype, # 241| &msg_flags); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:243: error[nullPointer]: Null pointer dereference: diediedie # 241| &msg_flags); # 242| if (infotype != SCTP_RECVV_NOINFO) # 243|-> tst_brkm(TBROK, tst_exit, "sctp_recvv infotype %d != %d", # 244| infotype, SCTP_RECVV_NOINFO); # 245| tst_resm(TPASS, "sctp_recvv SCTP_RECVV_NOINFO due to small size"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:248:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 246| # 247| rn_len = sizeof(struct sctp_nxtinfo); # 248|-> error = test_sctp_recvv(sk2, &iov, 1, (struct sockaddr *)&msgname, # 249| &msgname_len, &rn, &rn_len, &infotype, # 250| &msg_flags); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:252: error[nullPointer]: Null pointer dereference: diediedie # 250| &msg_flags); # 251| if (infotype != SCTP_RECVV_NXTINFO) # 252|-> tst_brkm(TBROK, tst_exit, "sctp_recvv infotype %d != %d", # 253| infotype, SCTP_RECVV_NXTINFO); # 254| tst_resm(TPASS, "sctp_recvv SCTP_RECVV_NXTINFO due to small size"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:257:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 255| # 256| rn_len = sizeof(rn); # 257|-> error = test_sctp_recvv(sk2, &iov, 1, (struct sockaddr *)&msgname, # 258| &msgname_len, &rn, &rn_len, &infotype, # 259| &msg_flags); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sctp_sendvrecvv.c:262: error[nullPointer]: Null pointer dereference: diediedie # 260| if (infotype != SCTP_RECVV_RN || # 261| rn.recvv_rcvinfo.rcv_sid != 0 || rn.recvv_nxtinfo.nxt_sid != 3) # 262|-> tst_brkm(TBROK, tst_exit, "sctp_recvv infotype %d != %d", # 263| infotype, SCTP_RECVV_RN); # 264| tst_resm(TPASS, "sctp_recvv SCTP_RECVV_RN"); Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:172: error[nullPointer]: Null pointer dereference: diediedie # 170| &optlen); # 171| if ((error != -1) && (errno != EINVAL)) # 172|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_STATUS) on a " # 173| "socket with no assoc error:%d errno:%d", # 174| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:172:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 170| &optlen); # 171| if ((error != -1) && (errno != EINVAL)) # 172|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_STATUS) on a " # 173| "socket with no assoc error:%d errno:%d", # 174| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:249: error[nullPointer]: Null pointer dereference: diediedie # 247| &optlen); # 248| if ((error != -1) && (errno != EINVAL)) # 249|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_STATUS) with " # 250| "associd error: %d errno:%d", error, errno); # 251| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:249:10: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 247| &optlen); # 248| if ((error != -1) && (errno != EINVAL)) # 249|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_STATUS) with " # 250| "associd error: %d errno:%d", error, errno); # 251| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:261: error[nullPointer]: Null pointer dereference: diediedie # 259| &optlen); # 260| if ((error != -1) && (errno != EINVAL)) # 261|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_STATUS) with " # 262| "NULL associd error: %d errno:%d", error, errno); # 263| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:261:10: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 259| &optlen); # 260| if ((error != -1) && (errno != EINVAL)) # 261|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_STATUS) with " # 262| "NULL associd error: %d errno:%d", error, errno); # 263| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:276:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 274| SCTP_ASSOC_CHANGE, SCTP_SHUTDOWN_COMP); # 275| # 276|-> error = 0; # 277| close(udp_svr_sk); # 278| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:336: error[nullPointer]: Null pointer dereference: diediedie # 334| /* Verify that we received the msg without any ancillary data. */ # 335| if (inmessage.msg_controllen != 0) # 336|-> tst_brkm(TBROK, tst_exit, "Receive unexpected ancillary" # 337| "data"); # 338| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:336:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 334| /* Verify that we received the msg without any ancillary data. */ # 335| if (inmessage.msg_controllen != 0) # 336|-> tst_brkm(TBROK, tst_exit, "Receive unexpected ancillary" # 337| "data"); # 338| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:345:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 343| sizeof(subscribe)); # 344| # 345|-> error = 0; # 346| /* Shut down the link. */ # 347| close(udp_clt_sk); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:422: error[nullPointer]: Null pointer dereference: diediedie # 420| (char *)&status1, &optlen); # 421| if (error != 0) # 422|-> tst_brkm(TBROK, tst_exit, # 423| "sctp_opt_info(SCTP_STATUS): %s", # 424| strerror(errno)); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:422:18: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 420| (char *)&status1, &optlen); # 421| if (error != 0) # 422|-> tst_brkm(TBROK, tst_exit, # 423| "sctp_opt_info(SCTP_STATUS): %s", # 424| strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:430: error[nullPointer]: Null pointer dereference: diediedie # 428| (char *)&status2, &optlen); # 429| if (error != 0) # 430|-> tst_brkm(TBROK, tst_exit, # 431| "getsockopt(SCTP_STATUS): %s", # 432| strerror(errno)); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:430:18: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 428| (char *)&status2, &optlen); # 429| if (error != 0) # 430|-> tst_brkm(TBROK, tst_exit, # 431| "getsockopt(SCTP_STATUS): %s", # 432| strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:434: error[nullPointer]: Null pointer dereference: diediedie # 432| strerror(errno)); # 433| if (strncmp((char *)&status1, (char *)&status2, optlen)) # 434|-> tst_brkm(TBROK, tst_exit, "sctp_opt_info(SCTP_STAUS)" # 435| "doesn't match getsockopt(SCTP_STATUS)"); # 436| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:434:18: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 432| strerror(errno)); # 433| if (strncmp((char *)&status1, (char *)&status2, optlen)) # 434|-> tst_brkm(TBROK, tst_exit, "sctp_opt_info(SCTP_STAUS)" # 435| "doesn't match getsockopt(SCTP_STATUS)"); # 436| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:439:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 437| tst_resm(TPASS, "sctp_opt_info(SCTP_STATUS)"); # 438| } # 439|-> error = 0; # 440| /* Shut down the link. */ # 441| close(udp_svr_sk); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:503: error[nullPointer]: Null pointer dereference: diediedie # 501| &optlen); # 502| if (paddrparams.spp_pathmaxrxt != dflt_pathmaxrxt+1) # 503|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 504| "mismatch"); # 505| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:503:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 501| &optlen); # 502| if (paddrparams.spp_pathmaxrxt != dflt_pathmaxrxt+1) # 503|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 504| "mismatch"); # 505| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:511: error[nullPointer]: Null pointer dereference: diediedie # 509| &optlen); # 510| if (value.assoc_value != 100) # 511|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DELAYED_ACK_TIME) " # 512| "mismatch"); # 513| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:511:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 509| &optlen); # 510| if (value.assoc_value != 100) # 511|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DELAYED_ACK_TIME) " # 512| "mismatch"); # 513| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:522: error[nullPointer]: Null pointer dereference: diediedie # 520| &optlen); # 521| if (paddrparams.spp_sackdelay != 250) # 522|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DELAYED_ACK_TIME) " # 523| "mismatch"); # 524| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:522:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 520| &optlen); # 521| if (paddrparams.spp_sackdelay != 250) # 522|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DELAYED_ACK_TIME) " # 523| "mismatch"); # 524| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:536: error[nullPointer]: Null pointer dereference: diediedie # 534| &optlen); # 535| if (paddrparams.spp_pathmaxrxt != dflt_pathmaxrxt) # 536|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_PEER_ADDR_PARAMS) " # 537| "mismatch"); # 538| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:536:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 534| &optlen); # 535| if (paddrparams.spp_pathmaxrxt != dflt_pathmaxrxt) # 536|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_PEER_ADDR_PARAMS) " # 537| "mismatch"); # 538| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:548: error[nullPointer]: Null pointer dereference: diediedie # 546| sizeof(paddrparams)); # 547| if ((-1 != error) || (EINVAL != errno)) # 548|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 549| "invalid associd error:%d, errno:%d\n", # 550| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:548:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 546| sizeof(paddrparams)); # 547| if ((-1 != error) || (EINVAL != errno)) # 548|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 549| "invalid associd error:%d, errno:%d\n", # 550| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:592: error[nullPointer]: Null pointer dereference: diediedie # 590| sizeof(paddrparams)); # 591| if ((-1 != error) || (EINVAL != errno)) # 592|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 593| "invalid transport error:%d, errno:%d\n", # 594| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:592:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 590| sizeof(paddrparams)); # 591| if ((-1 != error) || (EINVAL != errno)) # 592|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 593| "invalid transport error:%d, errno:%d\n", # 594| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:608: error[nullPointer]: Null pointer dereference: diediedie # 606| sizeof(paddrparams) - 1); # 607| if ((-1 != error) || (EINVAL != errno)) # 608|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 609| "invalid parameter length error:%d, errno:%d\n", # 610| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:608:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 606| sizeof(paddrparams) - 1); # 607| if ((-1 != error) || (EINVAL != errno)) # 608|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 609| "invalid parameter length error:%d, errno:%d\n", # 610| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:619: error[nullPointer]: Null pointer dereference: diediedie # 617| sizeof(value) - 1); # 618| if ((-1 != error) || (EINVAL != errno)) # 619|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DELAYED_ACK_TIME) " # 620| "invalid parameter length error:%d, errno:%d\n", # 621| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:619:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 617| sizeof(value) - 1); # 618| if ((-1 != error) || (EINVAL != errno)) # 619|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DELAYED_ACK_TIME) " # 620| "invalid parameter length error:%d, errno:%d\n", # 621| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:635: error[nullPointer]: Null pointer dereference: diediedie # 633| sizeof(paddrparams)); # 634| if ((-1 != error) || (EINVAL != errno)) # 635|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 636| "invalid sack delay error:%d, errno:%d\n", # 637| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:635:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 633| sizeof(paddrparams)); # 634| if ((-1 != error) || (EINVAL != errno)) # 635|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 636| "invalid sack delay error:%d, errno:%d\n", # 637| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:649: error[nullPointer]: Null pointer dereference: diediedie # 647| sizeof(value)); # 648| if ((-1 != error) || (EINVAL != errno)) # 649|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DELAYED_ACK_TIME) " # 650| "invalid sack delay error:%d, errno:%d\n", # 651| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:649:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 647| sizeof(value)); # 648| if ((-1 != error) || (EINVAL != errno)) # 649|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DELAYED_ACK_TIME) " # 650| "invalid sack delay error:%d, errno:%d\n", # 651| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:665: error[nullPointer]: Null pointer dereference: diediedie # 663| sizeof(paddrparams)); # 664| if ((-1 != error) || (EINVAL != errno)) # 665|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 666| "invalid path MTU error:%d, errno:%d\n", # 667| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:665:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 663| sizeof(paddrparams)); # 664| if ((-1 != error) || (EINVAL != errno)) # 665|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 666| "invalid path MTU error:%d, errno:%d\n", # 667| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:681: error[nullPointer]: Null pointer dereference: diediedie # 679| sizeof(paddrparams)); # 680| if ((-1 != error) || (EINVAL != errno)) # 681|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 682| "invalid hb enable flags error:%d, errno:%d\n", # 683| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:681:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 679| sizeof(paddrparams)); # 680| if ((-1 != error) || (EINVAL != errno)) # 681|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 682| "invalid hb enable flags error:%d, errno:%d\n", # 683| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:697: error[nullPointer]: Null pointer dereference: diediedie # 695| sizeof(paddrparams)); # 696| if ((-1 != error) || (EINVAL != errno)) # 697|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 698| "invalid PMTU discovery enable flags error:%d, errno:%d\n", # 699| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:697:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 695| sizeof(paddrparams)); # 696| if ((-1 != error) || (EINVAL != errno)) # 697|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 698| "invalid PMTU discovery enable flags error:%d, errno:%d\n", # 699| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:713: error[nullPointer]: Null pointer dereference: diediedie # 711| sizeof(paddrparams)); # 712| if ((-1 != error) || (EINVAL != errno)) # 713|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 714| "invalid sack delay enable flags error:%d, errno:%d\n", # 715| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:713:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 711| sizeof(paddrparams)); # 712| if ((-1 != error) || (EINVAL != errno)) # 713|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 714| "invalid sack delay enable flags error:%d, errno:%d\n", # 715| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:727: error[nullPointer]: Null pointer dereference: diediedie # 725| sizeof(paddrparams)); # 726| if ((-1 != error) || (EINVAL != errno)) # 727|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 728| "invalid hb demand error:%d, errno:%d\n", # 729| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:727:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 725| sizeof(paddrparams)); # 726| if ((-1 != error) || (EINVAL != errno)) # 727|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_PEER_ADDR_PARAMS) " # 728| "invalid hb demand error:%d, errno:%d\n", # 729| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:786: error[nullPointer]: Null pointer dereference: diediedie # 784| if (set_udp_sk_dflt_param.sinfo_ppid != # 785| get_udp_sk_dflt_param.sinfo_ppid) # 786|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 787| "mismatch."); # 788| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:786:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 784| if (set_udp_sk_dflt_param.sinfo_ppid != # 785| get_udp_sk_dflt_param.sinfo_ppid) # 786|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 787| "mismatch."); # 788| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:798: error[nullPointer]: Null pointer dereference: diediedie # 796| if (set_udp_sk_dflt_param.sinfo_ppid != # 797| get_udp_sk_dflt_param.sinfo_ppid) # 798|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 799| "mismatch."); # 800| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:798:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 796| if (set_udp_sk_dflt_param.sinfo_ppid != # 797| get_udp_sk_dflt_param.sinfo_ppid) # 798|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 799| "mismatch."); # 800| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:815: error[nullPointer]: Null pointer dereference: diediedie # 813| sizeof(set_udp_sk_dflt_param)); # 814| if ((-1 != error) || (EINVAL != errno)) # 815|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DEFAULT_SEND_PARAM) " # 816| "invalid associd error:%d, errno:%d\n", # 817| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:815:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 813| sizeof(set_udp_sk_dflt_param)); # 814| if ((-1 != error) || (EINVAL != errno)) # 815|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DEFAULT_SEND_PARAM) " # 816| "invalid associd error:%d, errno:%d\n", # 817| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:852: error[nullPointer]: Null pointer dereference: diediedie # 850| sizeof(set_udp_assoc_dflt_param)); # 851| if ((-1 != error) || (EINVAL != errno)) # 852|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DEFAULT_SEND_PARAM) " # 853| "associd belonging to another socket " # 854| "error:%d, errno:%d", error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:852:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 850| sizeof(set_udp_assoc_dflt_param)); # 851| if ((-1 != error) || (EINVAL != errno)) # 852|-> tst_brkm(TBROK, tst_exit, "setsockopt(SCTP_DEFAULT_SEND_PARAM) " # 853| "associd belonging to another socket " # 854| "error:%d, errno:%d", error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:884: error[nullPointer]: Null pointer dereference: diediedie # 882| if (get_udp_assoc_dflt_param.sinfo_ppid != # 883| set_udp_assoc_dflt_param.sinfo_ppid) # 884|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 885| "mismatch."); # 886| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:884:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 882| if (get_udp_assoc_dflt_param.sinfo_ppid != # 883| set_udp_assoc_dflt_param.sinfo_ppid) # 884|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 885| "mismatch."); # 886| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:903: error[nullPointer]: Null pointer dereference: diediedie # 901| if (get_udp_sk_dflt_param.sinfo_ppid != # 902| set_udp_sk_dflt_param.sinfo_ppid) # 903|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 904| "mismatch."); # 905| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:903:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 901| if (get_udp_sk_dflt_param.sinfo_ppid != # 902| set_udp_sk_dflt_param.sinfo_ppid) # 903|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 904| "mismatch."); # 905| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:925: error[nullPointer]: Null pointer dereference: diediedie # 923| if (get_peeloff_assoc_dflt_param.sinfo_ppid != # 924| set_udp_assoc_dflt_param.sinfo_ppid) # 925|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 926| "mismatch."); # 927| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:925:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 923| if (get_peeloff_assoc_dflt_param.sinfo_ppid != # 924| set_udp_assoc_dflt_param.sinfo_ppid) # 925|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 926| "mismatch."); # 927| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:961: error[nullPointer]: Null pointer dereference: diediedie # 959| if (set_tcp_sk_dflt_param.sinfo_ppid != # 960| get_tcp_sk_dflt_param.sinfo_ppid) # 961|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 962| "mismatch."); # 963| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:961:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 959| if (set_tcp_sk_dflt_param.sinfo_ppid != # 960| get_tcp_sk_dflt_param.sinfo_ppid) # 961|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 962| "mismatch."); # 963| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:973: error[nullPointer]: Null pointer dereference: diediedie # 971| if (set_tcp_sk_dflt_param.sinfo_ppid != # 972| get_tcp_sk_dflt_param.sinfo_ppid) # 973|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 974| "mismatch."); # 975| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:973:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 971| if (set_tcp_sk_dflt_param.sinfo_ppid != # 972| get_tcp_sk_dflt_param.sinfo_ppid) # 973|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 974| "mismatch."); # 975| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1005: error[nullPointer]: Null pointer dereference: diediedie # 1003| if (set_tcp_assoc_dflt_param.sinfo_ppid != # 1004| get_tcp_assoc_dflt_param.sinfo_ppid) # 1005|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1006| "mismatch."); # 1007| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1005:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 1003| if (set_tcp_assoc_dflt_param.sinfo_ppid != # 1004| get_tcp_assoc_dflt_param.sinfo_ppid) # 1005|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1006| "mismatch."); # 1007| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1021: error[nullPointer]: Null pointer dereference: diediedie # 1019| (get_tcp_sk_dflt_param.sinfo_ppid != # 1020| set_tcp_assoc_dflt_param.sinfo_ppid)) # 1021|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1022| "mismatch."); # 1023| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1021:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 1019| (get_tcp_sk_dflt_param.sinfo_ppid != # 1020| set_tcp_assoc_dflt_param.sinfo_ppid)) # 1021|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1022| "mismatch."); # 1023| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1035: error[nullPointer]: Null pointer dereference: diediedie # 1033| if (get_tcp_sk_dflt_param.sinfo_ppid != # 1034| set_tcp_sk_dflt_param.sinfo_ppid) # 1035|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1036| "mismatch."); # 1037| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1035:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 1033| if (get_tcp_sk_dflt_param.sinfo_ppid != # 1034| set_tcp_sk_dflt_param.sinfo_ppid) # 1035|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1036| "mismatch."); # 1037| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1051:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 1049| &get_accept_assoc_dflt_param, &optlen); # 1050| # 1051|-> error = 0; # 1052| # 1053| /* Verify that the get parameters returned matches the socket-wide Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1058: error[nullPointer]: Null pointer dereference: diediedie # 1056| if (get_tcp_sk_dflt_param.sinfo_ppid != # 1057| set_tcp_sk_dflt_param.sinfo_ppid) # 1058|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_DEFAULT_SEND_PARAM) " # 1059| "mismatch."); # 1060| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1071: error[nullPointer]: Null pointer dereference: diediedie # 1069| &pinfo, &optlen); # 1070| if ((-1 != error) || (EINVAL != errno)) # 1071|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_GET_PEER_ADDR_INFO) " # 1072| "null associd, null addr error:%d, errno:%d\n", # 1073| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1071:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 1069| &pinfo, &optlen); # 1070| if ((-1 != error) || (EINVAL != errno)) # 1071|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_GET_PEER_ADDR_INFO) " # 1072| "null associd, null addr error:%d, errno:%d\n", # 1073| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1085: error[nullPointer]: Null pointer dereference: diediedie # 1083| &pinfo, &optlen); # 1084| if ((-1 != error) || (EINVAL != errno)) # 1085|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_GET_PEER_ADDR_INFO) " # 1086| "valid associd, null addr error:%d, errno:%d\n", # 1087| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1085:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 1083| &pinfo, &optlen); # 1084| if ((-1 != error) || (EINVAL != errno)) # 1085|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_GET_PEER_ADDR_INFO) " # 1086| "valid associd, null addr error:%d, errno:%d\n", # 1087| error, errno); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1100: error[nullPointer]: Null pointer dereference: diediedie # 1098| &pinfo, &optlen); # 1099| if ((-1 != error) || (EINVAL != errno)) # 1100|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_GET_PEER_ADDR_INFO) " # 1101| "valid associd, invalid addr error:%d, errno:%d\n", # 1102| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1100:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 1098| &pinfo, &optlen); # 1099| if ((-1 != error) || (EINVAL != errno)) # 1100|-> tst_brkm(TBROK, tst_exit, "getsockopt(SCTP_GET_PEER_ADDR_INFO) " # 1101| "valid associd, invalid addr error:%d, errno:%d\n", # 1102| error, errno); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_sockopt.c:1132:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 1130| pinfo.spinfo_assoc_id = 0; # 1131| memcpy(&pinfo.spinfo_address, &tcp_clt_loop, sizeof(tcp_clt_loop)); # 1132|-> error = test_getsockopt(accept_sk, SCTP_GET_PEER_ADDR_INFO, &pinfo, # 1133| &optlen); # 1134| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:137: error[nullPointer]: Null pointer dereference: diediedie # 135| error = accept(clt_sk[0], &accept_loop.sa, &addrlen); # 136| if ((-1 != error) && (EINVAL != errno)) # 137|-> tst_brkm(TBROK, tst_exit, "accept on non-listening socket " # 138| "error:%d, errno:%d", error, errno); # 139| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:146: error[nullPointer]: Null pointer dereference: diediedie # 144| sizeof(clt_loop[0])); # 145| if ((-1 != error) && (EISCONN != errno)) # 146|-> tst_brkm(TBROK, tst_exit, "connect to non-listening socket " # 147| "error:%d, errno:%d", error, errno); # 148| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:162: error[nullPointer]: Null pointer dereference: diediedie # 160| error = connect(clt2_sk, &svr_loop.sa, sizeof(svr_loop)); # 161| if ((-1 != error) && (ECONNREFUSED != errno)) # 162|-> tst_brkm(TBROK, tst_exit, "connect after max backlog " # 163| "error:%d, errno:%d", error, errno); # 164| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:174: error[nullPointer]: Null pointer dereference: diediedie # 172| error = poll(&poll_fd, 1, -1); # 173| if ((1 != error) && (1 != poll_fd.revents)) # 174|-> tst_brkm(TBROK, tst_exit, "Unexpected return value " # 175| "with poll, error:%d errno:%d, revents:%d", # 176| error, errno, poll_fd.revents); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:188: error[nullPointer]: Null pointer dereference: diediedie # 186| error = connect(accept_sk[0], &clt_loop[0].sa, sizeof(clt_loop[0])); # 187| if ((-1 != error) || (EISCONN != errno)) # 188|-> tst_brkm(TBROK, tst_exit, "connect on an established socket " # 189| "error:%d errno:%d", error, errno); # 190| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:196: error[nullPointer]: Null pointer dereference: diediedie # 194| error = accept(accept_sk[0], &accept_loop.sa, &addrlen); # 195| if ((-1 != error) && (EINVAL != errno)) # 196|-> tst_brkm(TBROK, tst_exit, "accept on an established socket " # 197| "error:%d errno:%d", error, errno); # 198| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:201: error[nullPointer]: Null pointer dereference: diediedie # 199| error = accept(clt_sk[0], &accept_loop.sa, &addrlen); # 200| if ((-1 != error) && (EINVAL != errno)) # 201|-> tst_brkm(TBROK, tst_exit, "accept on an established socket " # 202| "failure: error:%d errno:%d", error, errno); # 203| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:229: error[nullPointer]: Null pointer dereference: diediedie # 227| error = send(listen_sk, message, strlen(message), MSG_NOSIGNAL); # 228| if ((-1 != error) || (EPIPE != errno)) # 229|-> tst_brkm(TBROK, tst_exit, "send on a listening socket " # 230| "error:%d, errno:%d", error, errno); # 231| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:237: error[nullPointer]: Null pointer dereference: diediedie # 235| error = recv(listen_sk, msgbuf, 100, 0); # 236| if ((-1 != error) || (ENOTCONN != errno)) # 237|-> tst_brkm(TBROK, tst_exit, "recv on a listening socket " # 238| "error:%d, errno:%d", error, errno); # 239| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:257: error[nullPointer]: Null pointer dereference: diediedie # 255| error = recv(accept_sk[0], msgbuf, 100, 0); # 256| if ((0 != error) || (0 != errno)) # 257|-> tst_brkm(TBROK, tst_exit, "recv on a SHUTDOWN received socket " # 258| "error:%d errno:%d", error, errno); # 259| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:288: error[nullPointer]: Null pointer dereference: diediedie # 286| error = recv(clt_sk[0], msgbuf, 100, 0); # 287| if ((-1 != error) || (ENOTCONN != errno)) # 288|-> tst_brkm(TBROK, tst_exit, "recv on a SHUTDOWN sent socket " # 289| "error:%d, errno:%d", error, errno); # 290| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:300: error[nullPointer]: Null pointer dereference: diediedie # 298| error = recv(clt_sk[1], msgbuf, 100, 0); # 299| if ((0 != error) || (0 != errno)) # 300|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RD socket " # 301| "error:%d, errno:%d", error, errno); # 302| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:315: error[nullPointer]: Null pointer dereference: diediedie # 313| error = recv(clt_sk[1], msgbuf, 100, 0); # 314| if ((0 != error) || (0 != errno)) # 315|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RD socket " # 316| "error:%d, errno:%d", error, errno); # 317| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:325: error[nullPointer]: Null pointer dereference: diediedie # 323| error = recv(accept_sk[2], msgbuf, 100, 0); # 324| if ((0 != error) || (0 != errno)) # 325|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RDWR socket " # 326| "error:%d, errno:%d", error, errno); # 327| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:330: error[nullPointer]: Null pointer dereference: diediedie # 328| error = recv(clt_sk[2], msgbuf, 100, 0); # 329| if ((0 != error) || (0 != errno)) # 330|-> tst_brkm(TBROK, tst_exit, "recv on a SHUT_RDWR socket " # 331| "error:%d, errno:%d", error, errno); # 332| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:335:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 333| tst_resm(TPASS, "recv on a SHUT_RDWR socket"); # 334| # 335|-> error = 0; # 336| # 337| for (i = 0; i < MAX_CLIENTS; i++) Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:357: error[nullPointer]: Null pointer dereference: diediedie # 355| error = select(listen_sk + 1, &set, NULL, NULL, NULL); # 356| if (1 != error) # 357|-> tst_brkm(TBROK, tst_exit, "select error:%d, " # 358| "errno: %d", error, errno); # 359| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:373: error[nullPointer]: Null pointer dereference: diediedie # 371| error = recv(accept2_sk, msgbuf, 100, 0); # 372| if ((0 != error) || (0 != errno)) # 373|-> tst_brkm(TBROK, tst_exit, "Unexpected error return on " # 374| "recv(error:%d, errno:%d)", error, errno); # 375| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:383: error[nullPointer]: Null pointer dereference: diediedie # 381| error = send(accept2_sk, message, strlen(message), MSG_NOSIGNAL); # 382| if ((-1 != error) || (EPIPE != errno)) # 383|-> tst_brkm(TBROK, tst_exit, "send to a CLOSED association " # 384| "error:%d, errno:%d", error, errno); # 385| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:388:2: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 386| tst_resm(TPASS, "send to a CLOSED association"); # 387| # 388|-> error = 0; # 389| close(accept2_sk); # 390| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:429: error[nullPointer]: Null pointer dereference: diediedie # 427| error = sendmsg(clt2_sk, &outmessage, 0); # 428| if ((-1 != error) || (EINVAL != errno)) # 429|-> tst_brkm(TBROK, tst_exit, "sendmsg with SCTP_EOF flag " # 430| "error:%d, errno:%d", error, errno); # 431| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_tcp_style.c:440: error[nullPointer]: Null pointer dereference: diediedie # 438| error = sendmsg(clt2_sk, &outmessage, 0); # 439| if ((-1 != error) || (EINVAL != errno)) # 440|-> tst_brkm(TBROK, tst_exit, "sendmsg with SCTP_ABORT flag " # 441| "error:%d, errno:%d", error, errno); # 442| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:152: error[nullPointer]: Null pointer dereference: diediedie # 150| &len); # 151| if (error) # 152|-> tst_brkm(TBROK, tst_exit, "can't get rcvbuf size: %s", # 153| strerror(errno)); # 154| /* Set the MAXSEG to something smallish. */ Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:152:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 150| &len); # 151| if (error) # 152|-> tst_brkm(TBROK, tst_exit, "can't get rcvbuf size: %s", # 153| strerror(errno)); # 154| /* Set the MAXSEG to something smallish. */ Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:182: error[nullPointer]: Null pointer dereference: diediedie # 180| sizeof(len)); # 181| if (error) # 182|-> tst_brkm(TBROK, tst_exit, "setsockopt(SO_RCVBUF): %s", # 183| strerror(errno)); # 184| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:182:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 180| sizeof(len)); # 181| if (error) # 182|-> tst_brkm(TBROK, tst_exit, "setsockopt(SO_RCVBUF): %s", # 183| strerror(errno)); # 184| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:253: error[nullPointer]: Null pointer dereference: diediedie # 251| # 252| if (error) # 253|-> tst_brkm(TBROK, tst_exit, "can't get rwnd size: %s", # 254| strerror(errno)); # 255| tst_resm(TINFO, "Creating fillmsg of size %d", Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:253:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 251| # 252| if (error) # 253|-> tst_brkm(TBROK, tst_exit, "can't get rwnd size: %s", # 254| strerror(errno)); # 255| tst_resm(TINFO, "Creating fillmsg of size %d", Error: GCC_ANALYZER_WARNING (CWE-688): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:273:9: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘fillmsg’ where non-null expected lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:255:9: note: in expansion of macro ‘tst_resm’ <built-in>: note: argument 1 of ‘__builtin_memset’ must be non-null # 271| sinfo->sinfo_ppid = ppid; # 272| sinfo->sinfo_stream = stream; # 273|-> memset(fillmsg, 'X', gstatus.sstat_rwnd+RWND_SLOP); # 274| fillmsg[gstatus.sstat_rwnd+RWND_SLOP-1] = '\0'; # 275| outmessage.msg_iov->iov_base = fillmsg; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:332:3: warning[deadcode.DeadStores]: Value stored to 'error' is never read # 330| do { # 331| inmessage.msg_controllen = sizeof(incmsg); # 332|-> error = test_recvmsg(sk2, &inmessage, MSG_WAITALL); # 333| } while (!(inmessage.msg_flags & MSG_EOR)); # 334| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:341: error[nullPointer]: Null pointer dereference: diediedie # 339| MSG_EOR, stream, ppid); # 340| if (0 != strncmp(iov.iov_base, nottlmsg, strlen(nottlmsg)+1)) # 341|-> tst_brkm(TBROK, tst_exit, "Received Wrong Message !!!"); # 342| # 343| tst_resm(TPASS, "Receive message with no timeout"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:341:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 339| MSG_EOR, stream, ppid); # 340| if (0 != strncmp(iov.iov_base, nottlmsg, strlen(nottlmsg)+1)) # 341|-> tst_brkm(TBROK, tst_exit, "Received Wrong Message !!!"); # 342| # 343| tst_resm(TPASS, "Receive message with no timeout"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:356: error[nullPointer]: Null pointer dereference: diediedie # 354| ssf = (struct sctp_send_failed *)iov.iov_base; # 355| if (0 != strncmp(ttlmsg, (char *)ssf->ssf_data, strlen(ttlmsg) + 1)) # 356|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 357| # 358| tst_resm(TPASS, "Receive SEND_FAILED for message with timeout"); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:356:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 354| ssf = (struct sctp_send_failed *)iov.iov_base; # 355| if (0 != strncmp(ttlmsg, (char *)ssf->ssf_data, strlen(ttlmsg) + 1)) # 356|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 357| # 358| tst_resm(TPASS, "Receive SEND_FAILED for message with timeout"); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:374: error[nullPointer]: Null pointer dereference: diediedie # 372| if (0 != strncmp(&ttlfrag[offset], (char *)ssf->ssf_data, # 373| SMALL_MAXSEG)) # 374|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 375| offset += SMALL_MAXSEG; # 376| } while (!(ssf->ssf_info.sinfo_flags & 0x01)); /* LAST_FRAG */ Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_timetolive.c:374:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 372| if (0 != strncmp(&ttlfrag[offset], (char *)ssf->ssf_data, # 373| SMALL_MAXSEG)) # 374|-> tst_brkm(TBROK, tst_exit, "SEND_FAILED data mismatch"); # 375| offset += SMALL_MAXSEG; # 376| } while (!(ssf->ssf_info.sinfo_flags & 0x01)); /* LAST_FRAG */ Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/addrs.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/connectx.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: COMPILER_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/connectx.c:92:12: warning[-Wattribute-alias=]: 'sctp_connectx_orig' alias between functions of incompatible types 'int(int)' and 'int(int, struct sockaddr *, int)' # 92 | extern int sctp_connectx_orig (int) # | ^~~~~~~~~~~~~~~~~~ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/connectx.c:80:5: note: aliased declaration here # 80 | int __sctp_connectx(int fd, struct sockaddr *addrs, int addrcnt) # | ^~~~~~~~~~~~~~~ # 90| # 91| SYMVER(sctp_connectx_orig, sctp_connectx@VERS_1) # 92|-> extern int sctp_connectx_orig (int) # 93| __attribute ((alias ("__sctp_connectx"))); # 94| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/recvmsg.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/sendmsg.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/lib/sendmsg.c:167:7: warning[core.NullDereference]: Access to field 'sa_family' results in a dereference of a null pointer (loaded from variable 'addr') # 165| # 166| addr = (struct sockaddr *)addrbuf; # 167|-> if (addr->sa_family == AF_INET) { # 168| struct sockaddr_in *a = (struct sockaddr_in *)addrbuf; # 169| Error: CPPCHECK_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches. Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:137:10: warning[deadcode.DeadStores]: Although the value stored to 'done' is used in the enclosing expression, the value is never actually read from 'done' # 135| text[msg_len-1] = save; # 136| # 137|-> if ( (done = !strcmp(text, "exit")) ) { break; } # 138| } # 139| } else { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:186: error[nullPointer]: Null pointer dereference: diediedie # 184| # 185| if (!(msg_flags & MSG_NOTIFICATION)) # 186|-> tst_brkm(TBROK, tst_exit, "Got a datamsg, expecting " # 187| "notification"); # 188| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:186:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 184| # 185| if (!(msg_flags & MSG_NOTIFICATION)) # 186|-> tst_brkm(TBROK, tst_exit, "Got a datamsg, expecting " # 187| "notification"); # 188| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:193: error[nullPointer]: Null pointer dereference: diediedie # 191| # 192| if (datalen != expected_datalen) # 193|-> tst_brkm(TBROK, tst_exit, "Got a notification of unexpected " # 194| "length:%d, expected length:%d", datalen, # 195| expected_datalen); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:193:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 191| # 192| if (datalen != expected_datalen) # 193|-> tst_brkm(TBROK, tst_exit, "Got a notification of unexpected " # 194| "length:%d, expected length:%d", datalen, # 195| expected_datalen); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:199: error[nullPointer]: Null pointer dereference: diediedie # 197| sn = (union sctp_notification *)buf; # 198| if (sn->sn_header.sn_type != expected_sn_type) # 199|-> tst_brkm(TBROK, tst_exit, "Unexpected notification:%d" # 200| "expected:%d", sn->sn_header.sn_type, # 201| expected_sn_type); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:199:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 197| sn = (union sctp_notification *)buf; # 198| if (sn->sn_header.sn_type != expected_sn_type) # 199|-> tst_brkm(TBROK, tst_exit, "Unexpected notification:%d" # 200| "expected:%d", sn->sn_header.sn_type, # 201| expected_sn_type); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:206: error[nullPointer]: Null pointer dereference: diediedie # 204| case SCTP_ASSOC_CHANGE: # 205| if (sn->sn_assoc_change.sac_state != expected_additional) # 206|-> tst_brkm(TBROK, tst_exit, "Unexpected sac_state:%d " # 207| "expected:%d", sn->sn_assoc_change.sac_state, # 208| expected_additional); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:206:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 204| case SCTP_ASSOC_CHANGE: # 205| if (sn->sn_assoc_change.sac_state != expected_additional) # 206|-> tst_brkm(TBROK, tst_exit, "Unexpected sac_state:%d " # 207| "expected:%d", sn->sn_assoc_change.sac_state, # 208| expected_additional); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:238: error[nullPointer]: Null pointer dereference: diediedie # 236| { # 237| if (msg_flags & MSG_NOTIFICATION) # 238|-> tst_brkm(TBROK, tst_exit, "Got a notification, expecting a" # 239| "datamsg"); # 240| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:238:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 236| { # 237| if (msg_flags & MSG_NOTIFICATION) # 238|-> tst_brkm(TBROK, tst_exit, "Got a notification, expecting a" # 239| "datamsg"); # 240| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:245: error[nullPointer]: Null pointer dereference: diediedie # 243| # 244| if (datalen != expected_datalen) # 245|-> tst_brkm(TBROK, tst_exit, "Got a datamsg of unexpected " # 246| "length:%d, expected length:%d", datalen, # 247| expected_datalen); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:245:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 243| # 244| if (datalen != expected_datalen) # 245|-> tst_brkm(TBROK, tst_exit, "Got a datamsg of unexpected " # 246| "length:%d, expected length:%d", datalen, # 247| expected_datalen); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:250: error[nullPointer]: Null pointer dereference: diediedie # 248| # 249| if ((msg_flags & ~0x80000000) != expected_msg_flags) # 250|-> tst_brkm(TBROK, tst_exit, "Unexpected msg_flags:0x%x " # 251| "expecting:0x%x", msg_flags, expected_msg_flags); # 252| Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:250:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 248| # 249| if ((msg_flags & ~0x80000000) != expected_msg_flags) # 250|-> tst_brkm(TBROK, tst_exit, "Unexpected msg_flags:0x%x " # 251| "expecting:0x%x", msg_flags, expected_msg_flags); # 252| Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:257: error[nullPointer]: Null pointer dereference: diediedie # 255| # 256| if (!sinfo) # 257|-> tst_brkm(TBROK, tst_exit, "Null sinfo, but expected " # 258| "stream:%d expected ppid:%d", expected_stream, # 259| expected_ppid); Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:257:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 255| # 256| if (!sinfo) # 257|-> tst_brkm(TBROK, tst_exit, "Null sinfo, but expected " # 258| "stream:%d expected ppid:%d", expected_stream, # 259| expected_ppid); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:262: error[nullPointer]: Null pointer dereference: diediedie # 260| # 261| if (sinfo->sinfo_stream != expected_stream) # 262|-> tst_brkm(TBROK, tst_exit, "stream mismatch: expected:%x " # 263| "got:%x", expected_stream, sinfo->sinfo_stream); # 264| if (sinfo->sinfo_ppid != expected_ppid) Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:262:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 260| # 261| if (sinfo->sinfo_stream != expected_stream) # 262|-> tst_brkm(TBROK, tst_exit, "stream mismatch: expected:%x " # 263| "got:%x", expected_stream, sinfo->sinfo_stream); # 264| if (sinfo->sinfo_ppid != expected_ppid) Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:265: error[nullPointer]: Null pointer dereference: diediedie # 263| "got:%x", expected_stream, sinfo->sinfo_stream); # 264| if (sinfo->sinfo_ppid != expected_ppid) # 265|-> tst_brkm(TBROK, tst_exit, "ppid mismatch: expected:%x " # 266| "got:%x\n", expected_ppid, sinfo->sinfo_ppid); # 267| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:265:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 263| "got:%x", expected_stream, sinfo->sinfo_stream); # 264| if (sinfo->sinfo_ppid != expected_ppid) # 265|-> tst_brkm(TBROK, tst_exit, "ppid mismatch: expected:%x " # 266| "got:%x\n", expected_ppid, sinfo->sinfo_ppid); # 267| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:313: error[nullPointer]: Null pointer dereference: diediedie # 311| msg_buf = (char *)malloc(len); # 312| if (!msg_buf) # 313|-> tst_brkm(TBROK, tst_exit, "malloc failed"); # 314| # 315| p = msg_buf; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:313:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 311| msg_buf = (char *)malloc(len); # 312| if (!msg_buf) # 313|-> tst_brkm(TBROK, tst_exit, "malloc failed"); # 314| # 315| p = msg_buf; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:357: error[nullPointer]: Null pointer dereference: diediedie # 355| sizeof(addr1->v4.sin_addr)); # 356| default: # 357|-> tst_brkm(TBROK, tst_exit, "invalid address type %d", # 358| addr1->sa.sa_family); # 359| return -1; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:357:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 355| sizeof(addr1->v4.sin_addr)); # 356| default: # 357|-> tst_brkm(TBROK, tst_exit, "invalid address type %d", # 358| addr1->sa.sa_family); # 359| return -1; Error: GCC_ANALYZER_WARNING (CWE-688): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c: scope_hint: In function 'test_peer_addr' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:372:9: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL 'found' where non-null expected <built-in>: note: argument 1 of '__builtin_memset' must be non-null # 370| void *addrbuf; # 371| char *found = (char *) malloc(count); # 372|-> memset(found, 0, count); # 373| # 374| error = sctp_getpaddrs(sk, asoc, &addrs); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:376: error[nullPointer]: Null pointer dereference: diediedie # 374| error = sctp_getpaddrs(sk, asoc, &addrs); # 375| if (-1 == error) { # 376|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs: %s", strerror(errno)); # 377| return error; # 378| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:376:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 374| error = sctp_getpaddrs(sk, asoc, &addrs); # 375| if (-1 == error) { # 376|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs: %s", strerror(errno)); # 377| return error; # 378| } Error: CPPCHECK_WARNING (CWE-401): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:377: error[memleak]: Memory leak: found # 375| if (-1 == error) { # 376| tst_brkm(TBROK, tst_exit, "sctp_getpaddrs: %s", strerror(errno)); # 377|-> return error; # 378| } # 379| if (error != count) { Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:381: error[nullPointer]: Null pointer dereference: diediedie # 379| if (error != count) { # 380| sctp_freepaddrs(addrs); # 381|-> tst_brkm(TBROK, tst_exit, "peer count %d mismatch, expected %d", # 382| error, count); # 383| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:381:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 379| if (error != count) { # 380| sctp_freepaddrs(addrs); # 381|-> tst_brkm(TBROK, tst_exit, "peer count %d mismatch, expected %d", # 382| error, count); # 383| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:399: error[nullPointer]: Null pointer dereference: diediedie # 397| errno = EINVAL; # 398| sctp_freepaddrs(addrs); # 399|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs: %s", strerror(errno)); # 400| return -1; # 401| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:399:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 397| errno = EINVAL; # 398| sctp_freepaddrs(addrs); # 399|-> tst_brkm(TBROK, tst_exit, "sctp_getpaddrs: %s", strerror(errno)); # 400| return -1; # 401| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:411: error[nullPointer]: Null pointer dereference: diediedie # 409| for (j = 0; j < count; j++) { # 410| if (found[j] == 0) { # 411|-> tst_brkm(TBROK, tst_exit, "peer address %d not found", j); # 412| } # 413| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:411:4: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 409| for (j = 0; j < count; j++) { # 410| if (found[j] == 0) { # 411|-> tst_brkm(TBROK, tst_exit, "peer address %d not found", j); # 412| } # 413| } Error: GCC_ANALYZER_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:54: included_from: Included from here. lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h: scope_hint: In function 'test_setsockopt' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:103:20: warning[-Wanalyzer-null-dereference]: dereference of NULL '0' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:121:17: note: in expansion of macro 'DUMP_CORE' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:257:17: note: in expansion of macro 'tst_brkm' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:257:17: note: in expansion of macro 'tst_brkm' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:121:17: note: in expansion of macro 'DUMP_CORE' lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:257:17: note: in expansion of macro 'tst_brkm' # 101| char *diediedie = 0; \ # 102| printf("DUMP_CORE %s: %d\n", __FILE__, __LINE__);\ # 103|-> *diediedie = 0; \ # 104| } # 105| Error: GCC_ANALYZER_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/nagle_snd.c:55: included_from: Included from here. lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h: scope_hint: In function ‘test_socket’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:103:20: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:121:17: note: in expansion of macro ‘DUMP_CORE’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:137:17: note: in expansion of macro ‘tst_brkm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:137:17: note: in expansion of macro ‘tst_brkm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:121:17: note: in expansion of macro ‘DUMP_CORE’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:137:17: note: in expansion of macro ‘tst_brkm’ # 101| char *diediedie = 0; \ # 102| printf("DUMP_CORE %s: %d\n", __FILE__, __LINE__);\ # 103|-> *diediedie = 0; \ # 104| } # 105| Error: GCC_ANALYZER_WARNING (CWE-775): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:120:17: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘accept(mkstemp(&filename), &acpt_addr, & len)’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:150:17: note: in expansion of macro ‘tst_brkm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:136:9: note: in expansion of macro ‘tst_resm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:150:17: note: in expansion of macro ‘tst_brkm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_accept_close.c:150:17: note: in expansion of macro ‘tst_brkm’ # 118| printf("%s %2d BROK : ", TCID, ++TST_CNT); \ # 119| printf(whatever); \ # 120|-> printf("\n"); \ # 121| DUMP_CORE \ # 122| } Error: GCC_ANALYZER_WARNING (CWE-775): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:120:17: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘accept(test_socket(2, 1, 132), &svr_addr, & len)’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:125:17: note: in expansion of macro ‘tst_brkm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:125:17: note: in expansion of macro ‘tst_brkm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_1_to_1_nonblock.c:125:17: note: in expansion of macro ‘tst_brkm’ # 118| printf("%s %2d BROK : ", TCID, ++TST_CNT); \ # 119| printf(whatever); \ # 120|-> printf("\n"); \ # 121| DUMP_CORE \ # 122| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:137: error[nullPointer]: Null pointer dereference: diediedie # 135| int sk = socket(domain, type, protocol); # 136| if (-1 == sk) # 137|-> tst_brkm(TBROK, tst_exit, "socket: %s", strerror(errno)); # 138| return sk; # 139| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/apps/nagle_rcv.c:56: included_from: Included from here. lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:137:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 135| int sk = socket(domain, type, protocol); # 136| if (-1 == sk) # 137|-> tst_brkm(TBROK, tst_exit, "socket: %s", strerror(errno)); # 138| return sk; # 139| } Error: GCC_ANALYZER_WARNING (CWE-666): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h: scope_hint: In function ‘test_bind’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:143:21: warning[-Wanalyzer-fd-phase-mismatch]: ‘bind’ on file descriptor ‘sk’ in wrong phase # 141| static inline int test_bind(int sk, struct sockaddr *addr, socklen_t addrlen) # 142| { # 143|-> int error = bind(sk, addr, addrlen); # 144| if (-1 == error) # 145| tst_brkm(TBROK, tst_exit, "bind: %s", strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:145: error[nullPointer]: Null pointer dereference: diediedie # 143| int error = bind(sk, addr, addrlen); # 144| if (-1 == error) # 145|-> tst_brkm(TBROK, tst_exit, "bind: %s", strerror(errno)); # 146| return error; # 147| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:145:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 143| int error = bind(sk, addr, addrlen); # 144| if (-1 == error) # 145|-> tst_brkm(TBROK, tst_exit, "bind: %s", strerror(errno)); # 146| return error; # 147| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:153: error[nullPointer]: Null pointer dereference: diediedie # 151| int error = sctp_bindx(sk, addr, count, SCTP_BINDX_ADD_ADDR); # 152| if (-1 == error) # 153|-> tst_brkm(TBROK, tst_exit, "bindx (add): %s", strerror(errno)); # 154| return error; # 155| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:161: error[nullPointer]: Null pointer dereference: diediedie # 159| int error = listen(sk, backlog); # 160| if (-1 == error) # 161|-> tst_brkm(TBROK, tst_exit, "listen: %s", strerror(errno)); # 162| return error; # 163| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:161:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 159| int error = listen(sk, backlog); # 160| if (-1 == error) # 161|-> tst_brkm(TBROK, tst_exit, "listen: %s", strerror(errno)); # 162| return error; # 163| } Error: GCC_ANALYZER_WARNING (CWE-666): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h: scope_hint: In function ‘test_connect’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:167:21: warning[-Wanalyzer-fd-phase-mismatch]: ‘connect’ on file descriptor ‘sk’ in wrong phase lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:101:9: note: in expansion of macro ‘tst_resm’ lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/func_tests/test_getname.c:111:9: note: in expansion of macro ‘tst_resm’ # 165| static inline int test_connect(int sk, struct sockaddr *addr, socklen_t addrlen) # 166| { # 167|-> int error = connect(sk, addr, addrlen); # 168| if (-1 == error) # 169| tst_brkm(TBROK, tst_exit, "connect: %s", strerror(errno)); Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:169: error[nullPointer]: Null pointer dereference: diediedie # 167| int error = connect(sk, addr, addrlen); # 168| if (-1 == error) # 169|-> tst_brkm(TBROK, tst_exit, "connect: %s", strerror(errno)); # 170| return error; # 171| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:169:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 167| int error = connect(sk, addr, addrlen); # 168| if (-1 == error) # 169|-> tst_brkm(TBROK, tst_exit, "connect: %s", strerror(errno)); # 170| return error; # 171| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:177: error[nullPointer]: Null pointer dereference: diediedie # 175| int error = sctp_connectx(sk, addr, count, NULL); # 176| if (-1 == error) # 177|-> tst_brkm(TBROK, tst_exit, "connectx: %s", strerror(errno)); # 178| return error; # 179| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:185: error[nullPointer]: Null pointer dereference: diediedie # 183| int error = accept(sk, addr, addrlen); # 184| if (-1 == error) # 185|-> tst_brkm(TBROK, tst_exit, "accept: %s", strerror(errno)); # 186| return error; # 187| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:185:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 183| int error = accept(sk, addr, addrlen); # 184| if (-1 == error) # 185|-> tst_brkm(TBROK, tst_exit, "accept: %s", strerror(errno)); # 186| return error; # 187| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:193: error[nullPointer]: Null pointer dereference: diediedie # 191| int error = send(sk, msg, len, flags); # 192| if (len != error) # 193|-> tst_brkm(TBROK, tst_exit, "send: error:%d errno:%d", # 194| error, errno); # 195| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:193:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 191| int error = send(sk, msg, len, flags); # 192| if (len != error) # 193|-> tst_brkm(TBROK, tst_exit, "send: error:%d errno:%d", # 194| error, errno); # 195| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:203: error[nullPointer]: Null pointer dereference: diediedie # 201| int error = sendto(sk, msg, len, flags, to, tolen); # 202| if (len != error) # 203|-> tst_brkm(TBROK, tst_exit, "sendto: error:%d errno:%d", # 204| error, errno); # 205| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:203:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 201| int error = sendto(sk, msg, len, flags, to, tolen); # 202| if (len != error) # 203|-> tst_brkm(TBROK, tst_exit, "sendto: error:%d errno:%d", # 204| error, errno); # 205| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:213: error[nullPointer]: Null pointer dereference: diediedie # 211| int error = sendmsg(sk, msg, flags); # 212| if (msglen != error) # 213|-> tst_brkm(TBROK, tst_exit, "sendmsg: error:%d errno:%d", # 214| error, errno); # 215| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:213:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 211| int error = sendmsg(sk, msg, flags); # 212| if (msglen != error) # 213|-> tst_brkm(TBROK, tst_exit, "sendmsg: error:%d errno:%d", # 214| error, errno); # 215| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:222: error[nullPointer]: Null pointer dereference: diediedie # 220| int error = recv(sk, buf, len, flags); # 221| if (-1 == error) # 222|-> tst_brkm(TBROK, tst_exit, "recv: %s", strerror(errno)); # 223| return error; # 224| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:222:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 220| int error = recv(sk, buf, len, flags); # 221| if (-1 == error) # 222|-> tst_brkm(TBROK, tst_exit, "recv: %s", strerror(errno)); # 223| return error; # 224| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:230: error[nullPointer]: Null pointer dereference: diediedie # 228| int error = recvmsg(sk, msg, flags); # 229| if (-1 == error) # 230|-> tst_brkm(TBROK, tst_exit, "recvmsg: %s", strerror(errno)); # 231| return error; # 232| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:230:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 228| int error = recvmsg(sk, msg, flags); # 229| if (-1 == error) # 230|-> tst_brkm(TBROK, tst_exit, "recvmsg: %s", strerror(errno)); # 231| return error; # 232| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:238: error[nullPointer]: Null pointer dereference: diediedie # 236| int error = shutdown(sk, how); # 237| if (-1 == error) # 238|-> tst_brkm(TBROK, tst_exit, "shutdown: %s", strerror(errno)); # 239| return error; # 240| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:238:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 236| int error = shutdown(sk, how); # 237| if (-1 == error) # 238|-> tst_brkm(TBROK, tst_exit, "shutdown: %s", strerror(errno)); # 239| return error; # 240| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:247: error[nullPointer]: Null pointer dereference: diediedie # 245| int error = getsockopt(sk, SOL_SCTP, optname, optval, optlen); # 246| if (error) # 247|-> tst_brkm(TBROK, tst_exit, "getsockopt(%d): %s", optname, # 248| strerror(errno)); # 249| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:247:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 245| int error = getsockopt(sk, SOL_SCTP, optname, optval, optlen); # 246| if (error) # 247|-> tst_brkm(TBROK, tst_exit, "getsockopt(%d): %s", optname, # 248| strerror(errno)); # 249| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:257: error[nullPointer]: Null pointer dereference: diediedie # 255| int error = setsockopt(sk, SOL_SCTP, optname, optval, optlen); # 256| if (error) # 257|-> tst_brkm(TBROK, tst_exit, "setsockopt(%d): %s", optname, # 258| strerror(errno)); # 259| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.c:54: included_from: Included from here. lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:257:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 255| int error = setsockopt(sk, SOL_SCTP, optname, optval, optlen); # 256| if (error) # 257|-> tst_brkm(TBROK, tst_exit, "setsockopt(%d): %s", optname, # 258| strerror(errno)); # 259| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:266: error[nullPointer]: Null pointer dereference: diediedie # 264| int error = sctp_peeloff(sk, assoc_id); # 265| if (-1 == error) # 266|-> tst_brkm(TBROK, tst_exit, "sctp_peeloff: %s", strerror(errno)); # 267| return error; # 268| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:266:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 264| int error = sctp_peeloff(sk, assoc_id); # 265| if (-1 == error) # 266|-> tst_brkm(TBROK, tst_exit, "sctp_peeloff: %s", strerror(errno)); # 267| return error; # 268| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:279: error[nullPointer]: Null pointer dereference: diediedie # 277| timetolive, context); # 278| if (len != error) # 279|-> tst_brkm(TBROK, tst_exit, "sctp_sendmsg: error:%d errno:%d", # 280| error, errno); # 281| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:279:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 277| timetolive, context); # 278| if (len != error) # 279|-> tst_brkm(TBROK, tst_exit, "sctp_sendmsg: error:%d errno:%d", # 280| error, errno); # 281| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:290: error[nullPointer]: Null pointer dereference: diediedie # 288| int error = sctp_send(s, msg, len, sinfo, flags); # 289| if (len != error) # 290|-> tst_brkm(TBROK, tst_exit, "sctp_send: error:%d errno:%d", # 291| error, errno); # 292| return error; Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:290:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 288| int error = sctp_send(s, msg, len, sinfo, flags); # 289| if (len != error) # 290|-> tst_brkm(TBROK, tst_exit, "sctp_send: error:%d errno:%d", # 291| error, errno); # 292| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:309: error[nullPointer]: Null pointer dereference: diediedie # 307| # 308| if (tlen != error) # 309|-> tst_brkm(TBROK, tst_exit, "sctp_sendv: error:%d errno:%d", # 310| error, errno); # 311| return error; Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:322: error[nullPointer]: Null pointer dereference: diediedie # 320| int error = sctp_recvmsg(sk, msg, len, from, fromlen, sinfo, msg_flags); # 321| if (-1 == error) # 322|-> tst_brkm(TBROK, tst_exit, "sctp_recvmsg: %s", strerror(errno)); # 323| return error; # 324| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:322:3: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 320| int error = sctp_recvmsg(sk, msg, len, from, fromlen, sinfo, msg_flags); # 321| if (-1 == error) # 322|-> tst_brkm(TBROK, tst_exit, "sctp_recvmsg: %s", strerror(errno)); # 323| return error; # 324| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:335: error[nullPointer]: Null pointer dereference: diediedie # 333| infotype, flags); # 334| if (-1 == error) # 335|-> tst_brkm(TBROK, tst_exit, "sctp_recvmsg: %s", strerror(errno)); # 336| return error; # 337| } Error: CPPCHECK_WARNING (CWE-476): lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:344: error[nullPointer]: Null pointer dereference: diediedie # 342| void *buf = malloc(size); # 343| if (NULL == buf) # 344|-> tst_brkm(TBROK, tst_exit, "malloc failed"); # 345| return buf; # 346| } Error: CLANG_WARNING: lksctp-tools-1.0.19-build/lksctp-tools-lksctp-tools-1.0.19/src/testlib/sctputil.h:344:17: warning[core.NullDereference]: Dereference of null pointer (loaded from variable 'diediedie') # 342| void *buf = malloc(size); # 343| if (NULL == buf) # 344|-> tst_brkm(TBROK, tst_exit, "malloc failed"); # 345| return buf; # 346| }