Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Nov 2020 15:57:14 +0000 (UTC)
From:      Adrian Chadd <adrian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r367248 - head/usr.bin/iscsictl
Message-ID:  <202011011557.0A1FvE0v003837@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: adrian
Date: Sun Nov  1 15:57:14 2020
New Revision: 367248
URL: https://svnweb.freebsd.org/changeset/base/367248

Log:
  [iscsictl] Fix compile issues that creep up with gcc-6.4
  
  This fixes two warnings:
  
  * double-definition of a symbol in a yacc header
  * Comparison of an unsigned int being >= 0; that's always
    going to be true.
  
  Reviewed by:	imp, rscheff
  Differential Revision:	https://reviews.freebsd.org/D27036

Modified:
  head/usr.bin/iscsictl/parse.y

Modified: head/usr.bin/iscsictl/parse.y
==============================================================================
--- head/usr.bin/iscsictl/parse.y	Sun Nov  1 11:34:15 2020	(r367247)
+++ head/usr.bin/iscsictl/parse.y	Sun Nov  1 15:57:14 2020	(r367248)
@@ -54,7 +54,6 @@ static struct conf *conf;
 static struct target *target;
 
 extern void	yyerror(const char *);
-extern int	yylex(void);
 extern void	yyrestart(FILE *);
 
 %}
@@ -359,7 +358,7 @@ pcp:	PCP EQUALS STR
 			free($3);
 			return(1);
 		}
-		if (!((tmp >=0) && (tmp <= 7))) {
+		if (tmp > 7) {
 			yyerror("invalid pcp value");
 			return(1);
 		}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202011011557.0A1FvE0v003837>