diff options
author | brian <brian@FreeBSD.org> | 1998-06-27 14:17:28 +0000 |
---|---|---|
committer | brian <brian@FreeBSD.org> | 1998-06-27 14:17:28 +0000 |
commit | 9666634a89fa23b0d1202c243cdc1224aa43c2e9 (patch) | |
tree | 35d9bd1c567aa322eca52f9c275e90ab7169459d /usr.sbin/ppp/bundle.c | |
parent | 6a5332c7c79dd1e6809f85f057a351c5f861749e (diff) | |
download | FreeBSD-src-9666634a89fa23b0d1202c243cdc1224aa43c2e9.zip FreeBSD-src-9666634a89fa23b0d1202c243cdc1224aa43c2e9.tar.gz |
Don't dlopen()/dlsym() libalias, use it in the same way
as the rest of the world uses libraries.
Diffstat (limited to 'usr.sbin/ppp/bundle.c')
-rw-r--r-- | usr.sbin/ppp/bundle.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/usr.sbin/ppp/bundle.c b/usr.sbin/ppp/bundle.c index 620426b..d9532c3 100644 --- a/usr.sbin/ppp/bundle.c +++ b/usr.sbin/ppp/bundle.c @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: bundle.c,v 1.24 1998/06/27 12:03:35 brian Exp $ + * $Id: bundle.c,v 1.25 1998/06/27 12:03:46 brian Exp $ */ #include <sys/param.h> @@ -37,6 +37,9 @@ #include <netinet/ip.h> #include <sys/un.h> +#ifndef NOALIAS +#include <alias.h> +#endif #include <errno.h> #include <fcntl.h> #include <paths.h> @@ -627,8 +630,8 @@ bundle_DescriptorRead(struct descriptor *d, struct bundle *bundle, struct mbuf *bp; #ifndef NOALIAS - if (alias_IsEnabled()) { - (*PacketAlias.In)(tun.data, sizeof tun.data); + if (bundle->AliasEnabled) { + PacketAliasIn(tun.data, sizeof tun.data); n = ntohs(((struct ip *)tun.data)->ip_len); } #endif @@ -668,8 +671,8 @@ bundle_DescriptorRead(struct descriptor *d, struct bundle *bundle, pri = PacketCheck(bundle, tun.data, n, &bundle->filter.out); if (pri >= 0) { #ifndef NOALIAS - if (alias_IsEnabled()) { - (*PacketAlias.Out)(tun.data, sizeof tun.data); + if (bundle->AliasEnabled) { + PacketAliasOut(tun.data, sizeof tun.data); n = ntohs(((struct ip *)tun.data)->ip_len); } #endif @@ -815,6 +818,7 @@ bundle_Create(const char *prefix, int type, const char **argv) bundle.routing_seq = 0; bundle.phase = PHASE_DEAD; bundle.CleaningUp = 0; + bundle.AliasEnabled = 0; bundle.fsm.LayerStart = bundle_LayerStart; bundle.fsm.LayerUp = bundle_LayerUp; |