X-Git-Url: https://git.ozlabs.org/?a=blobdiff_plain;f=pppd%2Fsys-svr4.c;h=859ab2ad3ab3422bf749048aced42f4f573753f6;hb=33c08b5f78f41aab4d1172e66db7c1afe21b5f1c;hp=6f164f9045dfc07ed364142bebabfecec7344fe0;hpb=cade394e607f2cd5f3e56be1eb1749e3afd7e410;p=ppp.git diff --git a/pppd/sys-svr4.c b/pppd/sys-svr4.c index 6f164f9..859ab2a 100644 --- a/pppd/sys-svr4.c +++ b/pppd/sys-svr4.c @@ -25,7 +25,7 @@ * OR MODIFICATIONS. */ -#define RCSID "$Id: sys-svr4.c,v 1.37 1999/10/29 00:30:26 masputra Exp $" +#define RCSID "$Id: sys-svr4.c,v 1.38 1999/11/13 19:19:17 masputra Exp $" #include #include @@ -98,7 +98,17 @@ static const char rcsid[] = RCSID; -static char *mux_dev_name; +#if defined(SOL2) +/* + * "/dev/udp" is used as a multiplexor to PLINK the interface stream + * under. It is used in place of "/dev/ip" since STREAMS will not let + * a driver be PLINK'ed under itself, and "/dev/ip" is typically the + * driver at the bottom of the tunneling interfaces stream. + */ +static char *mux_dev_name = UDP_DEV_NAME; +#else +static char *mux_dev_name = IP_DEV_NAME; +#endif static int pppfd; static int fdmuxid = -1; static int ipfd; @@ -364,18 +374,6 @@ sys_init() } reply; #endif /* !defined(SOL2) */ -#if defined(SOL2) - /* - * "/dev/udp" is used as a multiplexor to PLINK the interface stream - * under. It is used in place of "/dev/ip" since STREAMS will not let - * a driver be PLINK'ed under itself, and "/dev/ip" is typically the - * driver at the bottom of the tunneling interfaces stream. - */ - mux_dev_name = UDP_DEV_NAME; -#else - mux_dev_name = IP_DEV_NAME; -#endif - ipfd = open(mux_dev_name, O_RDWR, 0); if (ipfd < 0) fatal("Couldn't open IP device: %m");