Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/net/npf Add missing [0] (check for unused entries) when ...
details: https://anonhg.NetBSD.org/src/rev/93f2fc278f57
branches: trunk
changeset: 791275:93f2fc278f57
user: martin <martin%NetBSD.org@localhost>
date: Mon Nov 11 15:28:37 2013 +0000
description:
Add missing [0] (check for unused entries) when matching interface
names.
diffstat:
sys/net/npf/npf_if.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 6e8571a0e029 -r 93f2fc278f57 sys/net/npf/npf_if.c
--- a/sys/net/npf/npf_if.c Mon Nov 11 15:22:11 2013 +0000
+++ b/sys/net/npf/npf_if.c Mon Nov 11 15:28:37 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: npf_if.c,v 1.1 2013/11/08 00:38:26 rmind Exp $ */
+/* $NetBSD: npf_if.c,v 1.2 2013/11/11 15:28:37 martin Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: npf_if.c,v 1.1 2013/11/08 00:38:26 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: npf_if.c,v 1.2 2013/11/11 15:28:37 martin Exp $");
#ifdef _KERNEL_OPT
#include "pf.h"
@@ -98,7 +98,7 @@
for (u_int i = 0; i < npf_ifmap_cnt; i++) {
npf_ifmap_t *nim = &npf_ifmap[i];
- if (nim->n_ifname && strcmp(nim->n_ifname, ifname) == 0)
+ if (nim->n_ifname[0] && strcmp(nim->n_ifname, ifname) == 0)
return i + 1;
}
return INACTIVE_ID;
Home |
Main Index |
Thread Index |
Old Index