New Defects reported by Coverity Scan for freerangerouting/frr
Hi, Please find the latest report on new defect(s) introduced to freerangerouting/frr found with Coverity Scan. 28 new defect(s) introduced to freerangerouting/frr found with Coverity Scan. 4 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by Coverity Scan. New defect(s) Reported-by: Coverity Scan Showing 20 of 28 defect(s) ** CID 1448410: Control flow issues (DEADCODE) /lib/plist_clippy.c: 168 in no_ip_prefix_list_all() ________________________________________________________________________________________________________ *** CID 1448410: Control flow issues (DEADCODE) /lib/plist_clippy.c: 168 in no_ip_prefix_list_all() 162 continue; 163 _fail = 0; 164 if (!strcmp(argv[_i]->varname, "prefix_list")) { 165 prefix_list = argv[_i]->arg; 166 } 167 if (_fail)
CID 1448410: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
168 vty_out (vty, "%% invalid input for %s: %s%s", 169 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 170 _failcnt += _fail; 171 } 172 if (_failcnt) 173 return CMD_WARNING;
** CID 1448409: Control flow issues (DEADCODE) /lib/plist_clippy.c: 614 in ipv6_prefix_list_sequence_number() ________________________________________________________________________________________________________ *** CID 1448409: Control flow issues (DEADCODE) /lib/plist_clippy.c: 614 in ipv6_prefix_list_sequence_number() 608 if (_fail) 609 vty_out (vty, "%% invalid input for %s: %s%s", 610 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 611 _failcnt += _fail; 612 } 613 if (_failcnt)
CID 1448409: Control flow issues (DEADCODE) Execution cannot reach this statement: "return 1;".
614 return CMD_WARNING; 615 return ipv6_prefix_list_sequence_number_magic(self, vty, argc, argv, no); 616 } 617 618 /* show_ipv6_prefix_list => "show ipv6 prefix-list [WORD [seq$dseq (1-4294967295)$arg]]" */ 619 DEFUN_CMD_FUNC_DECL(show_ipv6_prefix_list)
** CID 1448408: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 25 in ip_prefix_list() ________________________________________________________________________________________________________ *** CID 1448408: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 25 in ip_prefix_list() 19 { 20 int _i; 21 unsigned _fail = 0, _failcnt = 0; 22 const char *prefix_list = NULL; 23 long seq = 0; 24 const char *seq_str = NULL;
CID 1448408: Null pointer dereferences (FORWARD_NULL) Assigning: "action" = "NULL".
25 const char *action = NULL; 26 const char *dest = NULL; 27 long ge = 0; 28 const char *ge_str = NULL; 29 long le = 0; 30 const char *le_str = NULL;
** CID 1448407: Control flow issues (DEADCODE) /lib/plist_clippy.c: 775 in show_ipv6_prefix_list_detail() ________________________________________________________________________________________________________ *** CID 1448407: Control flow issues (DEADCODE) /lib/plist_clippy.c: 775 in show_ipv6_prefix_list_detail() 769 if (_fail) 770 vty_out (vty, "%% invalid input for %s: %s%s", 771 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 772 _failcnt += _fail; 773 } 774 if (_failcnt)
CID 1448407: Control flow issues (DEADCODE) Execution cannot reach this statement: "return 1;".
775 return CMD_WARNING; 776 return show_ipv6_prefix_list_detail_magic(self, vty, argc, argv, prefix_list); 777 } 778 779 /* clear_ipv6_prefix_list => "clear ipv6 prefix-list [WORD [X:X::X:X/M$prefix]]" */ 780 DEFUN_CMD_FUNC_DECL(clear_ipv6_prefix_list)
** CID 1448406: Control flow issues (DEADCODE) /lib/plist_clippy.c: 770 in show_ipv6_prefix_list_detail() ________________________________________________________________________________________________________ *** CID 1448406: Control flow issues (DEADCODE) /lib/plist_clippy.c: 770 in show_ipv6_prefix_list_detail() 764 continue; 765 _fail = 0; 766 if (!strcmp(argv[_i]->varname, "prefix_list")) { 767 prefix_list = argv[_i]->arg; 768 } 769 if (_fail)
CID 1448406: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
770 vty_out (vty, "%% invalid input for %s: %s%s", 771 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 772 _failcnt += _fail; 773 } 774 if (_failcnt) 775 return CMD_WARNING;
** CID 1448405: Control flow issues (DEADCODE) /lib/plist_clippy.c: 743 in show_ipv6_prefix_list_summary() ________________________________________________________________________________________________________ *** CID 1448405: Control flow issues (DEADCODE) /lib/plist_clippy.c: 743 in show_ipv6_prefix_list_summary() 737 if (_fail) 738 vty_out (vty, "%% invalid input for %s: %s%s", 739 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 740 _failcnt += _fail; 741 } 742 if (_failcnt)
CID 1448405: Control flow issues (DEADCODE) Execution cannot reach this statement: "return 1;".
743 return CMD_WARNING; 744 return show_ipv6_prefix_list_summary_magic(self, vty, argc, argv, prefix_list); 745 } 746 747 /* show_ipv6_prefix_list_detail => "show ipv6 prefix-list detail [WORD$prefix-list]" */ 748 DEFUN_CMD_FUNC_DECL(show_ipv6_prefix_list_detail)
** CID 1448404: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 26 in ip_prefix_list() ________________________________________________________________________________________________________ *** CID 1448404: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 26 in ip_prefix_list() 20 int _i; 21 unsigned _fail = 0, _failcnt = 0; 22 const char *prefix_list = NULL; 23 long seq = 0; 24 const char *seq_str = NULL; 25 const char *action = NULL;
CID 1448404: Null pointer dereferences (FORWARD_NULL) Assigning: "dest" = "NULL".
26 const char *dest = NULL; 27 long ge = 0; 28 const char *ge_str = NULL; 29 long le = 0; 30 const char *le_str = NULL; 31
** CID 1448403: Control flow issues (DEADCODE) /lib/plist_clippy.c: 205 in ip_prefix_list_sequence_number() ________________________________________________________________________________________________________ *** CID 1448403: Control flow issues (DEADCODE) /lib/plist_clippy.c: 205 in ip_prefix_list_sequence_number() 199 if (_fail) 200 vty_out (vty, "%% invalid input for %s: %s%s", 201 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 202 _failcnt += _fail; 203 } 204 if (_failcnt)
CID 1448403: Control flow issues (DEADCODE) Execution cannot reach this statement: "return 1;".
205 return CMD_WARNING; 206 return ip_prefix_list_sequence_number_magic(self, vty, argc, argv, no); 207 } 208 209 /* show_ip_prefix_list => "show ip prefix-list [WORD [seq$dseq (1-4294967295)$arg]]" */ 210 DEFUN_CMD_FUNC_DECL(show_ip_prefix_list)
** CID 1448402: Control flow issues (DEADCODE) /lib/plist_clippy.c: 577 in no_ipv6_prefix_list_all() ________________________________________________________________________________________________________ *** CID 1448402: Control flow issues (DEADCODE) /lib/plist_clippy.c: 577 in no_ipv6_prefix_list_all() 571 continue; 572 _fail = 0; 573 if (!strcmp(argv[_i]->varname, "prefix_list")) { 574 prefix_list = argv[_i]->arg; 575 } 576 if (_fail)
CID 1448402: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
577 vty_out (vty, "%% invalid input for %s: %s%s", 578 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 579 _failcnt += _fail; 580 } 581 if (_failcnt) 582 return CMD_WARNING;
** CID 1448401: Control flow issues (DEADCODE) /lib/plist_clippy.c: 361 in show_ip_prefix_list_detail() ________________________________________________________________________________________________________ *** CID 1448401: Control flow issues (DEADCODE) /lib/plist_clippy.c: 361 in show_ip_prefix_list_detail() 355 continue; 356 _fail = 0; 357 if (!strcmp(argv[_i]->varname, "prefix_list")) { 358 prefix_list = argv[_i]->arg; 359 } 360 if (_fail)
CID 1448401: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
361 vty_out (vty, "%% invalid input for %s: %s%s", 362 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 363 _failcnt += _fail; 364 } 365 if (_failcnt) 366 return CMD_WARNING;
** CID 1448400: Null pointer dereferences (FORWARD_NULL) /lib/defun_lex.c: 1617 in def_yy_switch_to_buffer() ________________________________________________________________________________________________________ *** CID 1448400: Null pointer dereferences (FORWARD_NULL) /lib/defun_lex.c: 1617 in def_yy_switch_to_buffer() 1611 /* Flush out information for old buffer. */ 1612 *(yy_c_buf_p) = (yy_hold_char); 1613 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); 1614 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); 1615 } 1616
CID 1448400: Null pointer dereferences (FORWARD_NULL) Dereferencing null pointer "yy_buffer_stack".
1617 YY_CURRENT_BUFFER_LVALUE = new_buffer; 1618 def_yy_load_buffer_state( ); 1619 1620 /* We don't actually know whether we did this switch during 1621 * EOF (def_yywrap()) processing, but the only time this flag 1622 * is looked at is after def_yywrap() is called, so it's safe
** CID 1448399: Control flow issues (DEADCODE) /lib/plist_clippy.c: 738 in show_ipv6_prefix_list_summary() ________________________________________________________________________________________________________ *** CID 1448399: Control flow issues (DEADCODE) /lib/plist_clippy.c: 738 in show_ipv6_prefix_list_summary() 732 continue; 733 _fail = 0; 734 if (!strcmp(argv[_i]->varname, "prefix_list")) { 735 prefix_list = argv[_i]->arg; 736 } 737 if (_fail)
CID 1448399: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
738 vty_out (vty, "%% invalid input for %s: %s%s", 739 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 740 _failcnt += _fail; 741 } 742 if (_failcnt) 743 return CMD_WARNING;
** CID 1448398: Control flow issues (DEADCODE) /lib/plist_clippy.c: 609 in ipv6_prefix_list_sequence_number() ________________________________________________________________________________________________________ *** CID 1448398: Control flow issues (DEADCODE) /lib/plist_clippy.c: 609 in ipv6_prefix_list_sequence_number() 603 continue; 604 _fail = 0; 605 if (!strcmp(argv[_i]->varname, "no")) { 606 no = argv[_i]->arg; 607 } 608 if (_fail)
CID 1448398: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
609 vty_out (vty, "%% invalid input for %s: %s%s", 610 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 611 _failcnt += _fail; 612 } 613 if (_failcnt) 614 return CMD_WARNING;
** CID 1448397: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 435 in ipv6_prefix_list() ________________________________________________________________________________________________________ *** CID 1448397: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 435 in ipv6_prefix_list() 429 int _i; 430 unsigned _fail = 0, _failcnt = 0; 431 const char *prefix_list = NULL; 432 long seq = 0; 433 const char *seq_str = NULL; 434 const char *action = NULL;
CID 1448397: Null pointer dereferences (FORWARD_NULL) Assigning: "dest" = "NULL".
435 const char *dest = NULL; 436 long ge = 0; 437 const char *ge_str = NULL; 438 long le = 0; 439 const char *le_str = NULL; 440
** CID 1448396: Null pointer dereferences (FORWARD_NULL) /lib/defun_lex.c: 1585 in def_yyrestart() ________________________________________________________________________________________________________ *** CID 1448396: Null pointer dereferences (FORWARD_NULL) /lib/defun_lex.c: 1585 in def_yyrestart() 1579 */ 1580 void def_yyrestart (FILE * input_file ) 1581 { 1582 1583 if ( ! YY_CURRENT_BUFFER ){ 1584 def_yyensure_buffer_stack ();
CID 1448396: Null pointer dereferences (FORWARD_NULL) Dereferencing null pointer "yy_buffer_stack".
1585 YY_CURRENT_BUFFER_LVALUE = 1586 def_yy_create_buffer(def_yyin,YY_BUF_SIZE ); 1587 } 1588 1589 def_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); 1590 def_yy_load_buffer_state( );
** CID 1448395: Control flow issues (DEADCODE) /lib/plist_clippy.c: 334 in show_ip_prefix_list_summary() ________________________________________________________________________________________________________ *** CID 1448395: Control flow issues (DEADCODE) /lib/plist_clippy.c: 334 in show_ip_prefix_list_summary() 328 if (_fail) 329 vty_out (vty, "%% invalid input for %s: %s%s", 330 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 331 _failcnt += _fail; 332 } 333 if (_failcnt)
CID 1448395: Control flow issues (DEADCODE) Execution cannot reach this statement: "return 1;".
334 return CMD_WARNING; 335 return show_ip_prefix_list_summary_magic(self, vty, argc, argv, prefix_list); 336 } 337 338 /* show_ip_prefix_list_detail => "show ip prefix-list detail [WORD$prefix_list]" */ 339 DEFUN_CMD_FUNC_DECL(show_ip_prefix_list_detail)
** CID 1448394: Null pointer dereferences (NULL_RETURNS) /watchfrr/watchfrr.c: 672 in daemon_send_ready() ________________________________________________________________________________________________________ *** CID 1448394: Null pointer dereferences (NULL_RETURNS) /watchfrr/watchfrr.c: 672 in daemon_send_ready() 666 { 667 static int sent = 0; 668 if (!sent && gs.numdown == 0) { 669 FILE *fp; 670 671 fp = fopen(DAEMON_VTY_DIR "/watchfrr.started", "w");
CID 1448394: Null pointer dereferences (NULL_RETURNS) Dereferencing a pointer that might be null "fp" when calling "fclose".
672 fclose(fp); 673 zlog_notice 674 ("Watchfrr: Notifying Systemd we are up and running"); 675 systemd_send_started(master, 0); 676 sent = 1; 677 }
** CID 1448393: Control flow issues (DEADCODE) /lib/plist_clippy.c: 366 in show_ip_prefix_list_detail() ________________________________________________________________________________________________________ *** CID 1448393: Control flow issues (DEADCODE) /lib/plist_clippy.c: 366 in show_ip_prefix_list_detail() 360 if (_fail) 361 vty_out (vty, "%% invalid input for %s: %s%s", 362 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 363 _failcnt += _fail; 364 } 365 if (_failcnt)
CID 1448393: Control flow issues (DEADCODE) Execution cannot reach this statement: "return 1;".
366 return CMD_WARNING; 367 return show_ip_prefix_list_detail_magic(self, vty, argc, argv, prefix_list); 368 } 369 370 /* clear_ip_prefix_list => "clear ip prefix-list [WORD [A.B.C.D/M$prefix]]" */ 371 DEFUN_CMD_FUNC_DECL(clear_ip_prefix_list)
** CID 1448392: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 431 in ipv6_prefix_list() ________________________________________________________________________________________________________ *** CID 1448392: Null pointer dereferences (FORWARD_NULL) /lib/plist_clippy.c: 431 in ipv6_prefix_list() 425 const char * le_str __attribute__ ((unused))) 426 funcdecl_ipv6_prefix_list; 427 DEFUN_CMD_FUNC_TEXT(ipv6_prefix_list) 428 { 429 int _i; 430 unsigned _fail = 0, _failcnt = 0;
CID 1448392: Null pointer dereferences (FORWARD_NULL) Assigning: "prefix_list" = "NULL".
431 const char *prefix_list = NULL; 432 long seq = 0; 433 const char *seq_str = NULL; 434 const char *action = NULL; 435 const char *dest = NULL; 436 long ge = 0;
** CID 1448391: Control flow issues (DEADCODE) /lib/plist_clippy.c: 329 in show_ip_prefix_list_summary() ________________________________________________________________________________________________________ *** CID 1448391: Control flow issues (DEADCODE) /lib/plist_clippy.c: 329 in show_ip_prefix_list_summary() 323 continue; 324 _fail = 0; 325 if (!strcmp(argv[_i]->varname, "prefix_list")) { 326 prefix_list = argv[_i]->arg; 327 } 328 if (_fail)
CID 1448391: Control flow issues (DEADCODE) Execution cannot reach the expression "vty_out" inside this statement: "vty_out(vty, "%% invalid in...".
329 vty_out (vty, "%% invalid input for %s: %s%s", 330 argv[_i]->varname, argv[_i]->arg, VTY_NEWLINE); 331 _failcnt += _fail; 332 } 333 if (_failcnt) 334 return CMD_WARNING;
________________________________________________________________________________________________________ To view the defects in Coverity Scan visit, https://u2389337.ct.sendgrid.net/wf/click?upn=08onrYu34A-2BWcWUl-2F-2BfV0V05... To manage Coverity Scan email notifications for "frr@lists.nox.tf", click https://u2389337.ct.sendgrid.net/wf/click?upn=08onrYu34A-2BWcWUl-2F-2BfV0V05...
participants (1)
-
scan-admin@coverity.com