Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Aug 2016 10:26:15 +0000 (UTC)
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r304378 - head/sys/netpfil/ipfw/nat64
Message-ID:  <201608181026.u7IAQFjG018561@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bz
Date: Thu Aug 18 10:26:15 2016
New Revision: 304378
URL: https://svnweb.freebsd.org/changeset/base/304378

Log:
  Try to fix gcc compilation errors (which are right).
  nat64_getlasthdr() returns an int, which can be -1 in case of error,
  storing the result in an uint8_t and then comparing to < 0 is not
  helpful.  Do what is done in the rest of the code and make proto an
  int here as well.

Modified:
  head/sys/netpfil/ipfw/nat64/nat64_translate.c

Modified: head/sys/netpfil/ipfw/nat64/nat64_translate.c
==============================================================================
--- head/sys/netpfil/ipfw/nat64/nat64_translate.c	Thu Aug 18 10:25:07 2016	(r304377)
+++ head/sys/netpfil/ipfw/nat64/nat64_translate.c	Thu Aug 18 10:26:15 2016	(r304378)
@@ -1415,8 +1415,7 @@ nat64_do_handle_ip6(struct mbuf *m, uint
 	struct sockaddr *dst;
 	uint16_t *csum;
 	uint32_t mtu;
-	int plen, hlen;
-	uint8_t proto;
+	int plen, hlen, proto;
 
 	/*
 	 * XXX: we expect ipfw_chk() did m_pullup() up to upper level



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