From 697711be2cf6b5da140b8c12c301affa53488021 Mon Sep 17 00:00:00 2001 From: Pavel Machek Date: Sun, 26 Mar 2000 18:00:45 +0000 Subject: [PATCH] if_connected is usefull outside of neighbour cache. --- nest/iface.h | 2 ++ nest/neighbor.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/nest/iface.h b/nest/iface.h index e8e4e733..8540a4de 100644 --- a/nest/iface.h +++ b/nest/iface.h @@ -121,6 +121,8 @@ void neigh_if_up(struct iface *); void neigh_if_down(struct iface *); void neigh_init(struct pool *); +extern int if_connected(ip_addr *a, struct iface *i) /* -1=error, 1=match, 0=no match */ + /* * Interface Pattern Lists */ diff --git a/nest/neighbor.c b/nest/neighbor.c index c4328b6c..5750f8cf 100644 --- a/nest/neighbor.c +++ b/nest/neighbor.c @@ -24,7 +24,7 @@ neigh_hash(struct proto *p, ip_addr *a) return (p->hash_key ^ ipa_hash(*a)) & (NEIGH_HASH_SIZE-1); } -static int +int if_connected(ip_addr *a, struct iface *i) /* -1=error, 1=match, 0=no match */ { struct ifa *b;