svn commit: r289171 - stable/9/sbin/ipfw

Andrey V. Elsukov ae at FreeBSD.org
Mon Oct 12 07:53:05 UTC 2015


Author: ae
Date: Mon Oct 12 07:53:04 2015
New Revision: 289171
URL: https://svnweb.freebsd.org/changeset/base/289171

Log:
  MFC r288528:
    Fix possible segmentation fault.
  
    PR:		203494

Modified:
  stable/9/sbin/ipfw/ipfw2.c
Directory Properties:
  stable/9/sbin/ipfw/   (props changed)

Modified: stable/9/sbin/ipfw/ipfw2.c
==============================================================================
--- stable/9/sbin/ipfw/ipfw2.c	Mon Oct 12 07:50:27 2015	(r289170)
+++ stable/9/sbin/ipfw/ipfw2.c	Mon Oct 12 07:53:04 2015	(r289171)
@@ -2979,7 +2979,7 @@ ipfw_add(char *av[])
 		action->opcode = O_NAT;
 		action->len = F_INSN_SIZE(ipfw_insn_nat);
 		CHECK_ACTLEN;
-		if (_substrcmp(*av, "global") == 0) {
+		if (*av != NULL && _substrcmp(*av, "global") == 0) {
 			action->arg1 = 0;
 			av++;
 			break;


More information about the svn-src-stable-9 mailing list