Skip to content

Commit

Permalink
netfilter: ip6t_LOG: fix a flaw in printing the MAC
Browse files Browse the repository at this point in the history
The flaw was in skipping the second byte in MAC header due to increasing
the pointer AND indexed access starting at '1'.

Signed-off-by: Joerg Marx <joerg.marx@secunet.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
  • Loading branch information
Joerg Marx authored and Patrick McHardy committed Feb 17, 2011
1 parent d503b30 commit 0af320f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ipv6/netfilter/ip6t_LOG.c
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ static void dump_mac_header(struct sbuff *m,
if (p != NULL) {
sb_add(m, "%02x", *p++);
for (i = 1; i < len; i++)
sb_add(m, ":%02x", p[i]);
sb_add(m, ":%02x", *p++);
}
sb_add(m, " ");

Expand Down

0 comments on commit 0af320f

Please sign in to comment.