lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <18584.14648.22535.119913@robur.slu.se>
Date:	Tue, 5 Aug 2008 13:27:52 +0200
From:	Robert Olsson <robert@...ur.slu.se>
To:	David Miller <davem@...emloft.net>
Cc:	netdev@...r.kernel.org, eneas.hunguana@...il.com,
	robert@...ur.slu.se
Subject: [PATCH] pktgen mac count



One more...

dst_mac_count and src_mac_count patch from Eneas Hunguana
We have sent one mac address to much.


Signed-off-by: Robert Olsson <robert.olsson@....uu.se>

Cheers.
					--ro


--- a/net/core/pktgen.c	2008-06-09 20:27:19.000000000 +0200
+++ b/net/core/pktgen.c	2008-07-06 03:06:00.000000000 +0200
@@ -2143,7 +2143,7 @@
 			mc = random32() % pkt_dev->src_mac_count;
 		else {
 			mc = pkt_dev->cur_src_mac_offset++;
-			if (pkt_dev->cur_src_mac_offset >
+			if (pkt_dev->cur_src_mac_offset >=
 			    pkt_dev->src_mac_count)
 				pkt_dev->cur_src_mac_offset = 0;
 		}
@@ -2170,7 +2170,7 @@
 
 		else {
 			mc = pkt_dev->cur_dst_mac_offset++;
-			if (pkt_dev->cur_dst_mac_offset >
+			if (pkt_dev->cur_dst_mac_offset >=
 			    pkt_dev->dst_mac_count) {
 				pkt_dev->cur_dst_mac_offset = 0;
 			}

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ