Deleted Added
full compact
datalink.c (79165) datalink.c (81634)
1/*-
2 * Copyright (c) 1998 Brian Somers <brian@Awfulhak.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
1/*-
2 * Copyright (c) 1998 Brian Somers <brian@Awfulhak.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $FreeBSD: head/usr.sbin/ppp/datalink.c 79165 2001-07-03 22:20:19Z brian $
26 * $FreeBSD: head/usr.sbin/ppp/datalink.c 81634 2001-08-14 16:05:52Z brian $
27 */
28
29#include <sys/param.h>
30#include <netinet/in.h>
31#include <netinet/in_systm.h>
32#include <netinet/ip.h>
27 */
28
29#include <sys/param.h>
30#include <netinet/in.h>
31#include <netinet/in_systm.h>
32#include <netinet/ip.h>
33#include <sys/socket.h>
33#include <sys/un.h>
34
35#include <ctype.h>
36#include <stdio.h>
37#include <stdlib.h>
38#include <string.h>
39#include <sys/uio.h>
40#include <termios.h>

--- 10 unchanged lines hidden (view full) ---

51#include "lcp.h"
52#include "async.h"
53#include "throughput.h"
54#include "ccp.h"
55#include "link.h"
56#include "physical.h"
57#include "iplist.h"
58#include "slcompress.h"
34#include <sys/un.h>
35
36#include <ctype.h>
37#include <stdio.h>
38#include <stdlib.h>
39#include <string.h>
40#include <sys/uio.h>
41#include <termios.h>

--- 10 unchanged lines hidden (view full) ---

52#include "lcp.h"
53#include "async.h"
54#include "throughput.h"
55#include "ccp.h"
56#include "link.h"
57#include "physical.h"
58#include "iplist.h"
59#include "slcompress.h"
60#include "ncpaddr.h"
61#include "ip.h"
59#include "ipcp.h"
60#include "filter.h"
61#include "mp.h"
62#ifndef NORADIUS
63#include "radius.h"
64#endif
62#include "ipcp.h"
63#include "filter.h"
64#include "mp.h"
65#ifndef NORADIUS
66#include "radius.h"
67#endif
68#include "ipv6cp.h"
69#include "ncp.h"
65#include "bundle.h"
66#include "chat.h"
67#include "auth.h"
68#include "prompt.h"
69#include "proto.h"
70#include "pap.h"
71#include "chap.h"
72#include "command.h"

--- 544 unchanged lines hidden (view full) ---

617 } else if (bundle_Phase(dl->bundle) == PHASE_NETWORK) {
618 log_Printf(LogPHASE, "%s: Already in NETWORK phase\n", dl->name);
619 datalink_NewState(dl, DATALINK_OPEN);
620 bundle_CalculateBandwidth(dl->bundle);
621 (*dl->parent->LayerUp)(dl->parent->object, &dl->physical->link.lcp.fsm);
622 return;
623 } else {
624 dl->bundle->ncp.mp.peer = dl->peer;
70#include "bundle.h"
71#include "chat.h"
72#include "auth.h"
73#include "prompt.h"
74#include "proto.h"
75#include "pap.h"
76#include "chap.h"
77#include "command.h"

--- 544 unchanged lines hidden (view full) ---

622 } else if (bundle_Phase(dl->bundle) == PHASE_NETWORK) {
623 log_Printf(LogPHASE, "%s: Already in NETWORK phase\n", dl->name);
624 datalink_NewState(dl, DATALINK_OPEN);
625 bundle_CalculateBandwidth(dl->bundle);
626 (*dl->parent->LayerUp)(dl->parent->object, &dl->physical->link.lcp.fsm);
627 return;
628 } else {
629 dl->bundle->ncp.mp.peer = dl->peer;
625 ipcp_SetLink(&dl->bundle->ncp.ipcp, &dl->physical->link);
630 ncp_SetLink(&dl->bundle->ncp, &dl->physical->link);
626 auth_Select(dl->bundle, dl->peer.authname);
627 }
628
629 if (ccpok) {
630 fsm_Up(&dl->physical->link.ccp.fsm);
631 fsm_Open(&dl->physical->link.ccp.fsm);
632 }
633 datalink_NewState(dl, DATALINK_OPEN);

--- 818 unchanged lines hidden ---
631 auth_Select(dl->bundle, dl->peer.authname);
632 }
633
634 if (ccpok) {
635 fsm_Up(&dl->physical->link.ccp.fsm);
636 fsm_Open(&dl->physical->link.ccp.fsm);
637 }
638 datalink_NewState(dl, DATALINK_OPEN);

--- 818 unchanged lines hidden ---