Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/net apply the smallest hack to allow this to build witho...
details: https://anonhg.NetBSD.org/src/rev/07ed614ac754
branches: trunk
changeset: 759298:07ed614ac754
user: mrg <mrg%NetBSD.org@localhost>
date: Sun Dec 05 08:45:46 2010 +0000
description:
apply the smallest hack to allow this to build without warnings again.
diffstat:
sys/net/bpf_filter.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diffs (33 lines):
diff -r eff1806c0b0a -r 07ed614ac754 sys/net/bpf_filter.c
--- a/sys/net/bpf_filter.c Sun Dec 05 08:43:23 2010 +0000
+++ b/sys/net/bpf_filter.c Sun Dec 05 08:45:46 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bpf_filter.c,v 1.38 2010/12/05 02:40:40 christos Exp $ */
+/* $NetBSD: bpf_filter.c,v 1.39 2010/12/05 08:45:46 mrg Exp $ */
/*-
* Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bpf_filter.c,v 1.38 2010/12/05 02:40:40 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bpf_filter.c,v 1.39 2010/12/05 08:45:46 mrg Exp $");
#if 0
#if !(defined(lint) || defined(KERNEL))
@@ -462,11 +462,12 @@
* Otherwise, a bogus program could easily crash the system.
*/
int
-bpf_validate(const struct bpf_insn *f, int len)
+bpf_validate(const struct bpf_insn *f, int signed_len)
{
- u_int i, from;
+ u_int i, from, len;
const struct bpf_insn *p;
+ len = (u_int)signed_len;
if (len < 1)
return 0;
#if defined(KERNEL) || defined(_KERNEL)
Home |
Main Index |
Thread Index |
Old Index