~ubuntu-branches/ubuntu/feisty/net-tools/feisty

« back to all changes in this revision

Viewing changes to lib/hdlclapb.c

  • Committer: Bazaar Package Importer
  • Author(s): Bernd Eckenfels
  • Date: 2001-11-24 06:26:37 UTC
  • Revision ID: james.westby@ubuntu.com-20011124062637-1y96kzx03e8dbi55
Tags: upstream-1.60
ImportĀ upstreamĀ versionĀ 1.60

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * lib/hdlclapb.c 
 
3
 *              This file contains the HDLC/LAPB support for the NET-2 base
 
4
 *              distribution.
 
5
 *
 
6
 * Version:    $Id: hdlclapb.c,v 1.5 2000/03/05 11:26:02 philip Exp $
 
7
 *
 
8
 * Original Author:     
 
9
 *              Fred N. van Kempen, <waltje@uwalt.nl.mugnet.org>
 
10
 *              Copyright 1993 MicroWalt Corporation
 
11
 *
 
12
 *              Modified by Alan Cox, May 94 to cover NET-3
 
13
 *
 
14
 *              This program is free software; you can redistribute it
 
15
 *              and/or  modify it under  the terms of  the GNU General
 
16
 *              Public  License as  published  by  the  Free  Software
 
17
 *              Foundation;  either  version 2 of the License, or  (at
 
18
 *              your option) any later version.
 
19
 */
 
20
#include "config.h"
 
21
 
 
22
#if HAVE_HWHDLCLAPB
 
23
 
 
24
#include <sys/types.h>
 
25
#include <sys/ioctl.h>
 
26
#include <sys/socket.h>
 
27
#include <net/if_arp.h>
 
28
#include <stdlib.h>
 
29
#include <stdio.h>
 
30
#include <ctype.h>
 
31
#include <errno.h>
 
32
#include <fcntl.h>
 
33
#include <string.h>
 
34
#include <termios.h>
 
35
#include <unistd.h>
 
36
#include "net-support.h"
 
37
#include "pathnames.h"
 
38
 
 
39
#ifndef ARPHRD_HDLC
 
40
#warning "No definition of ARPHRD_HDLC in <net/if_arp.h>, using private value 513"
 
41
#define ARPHRD_HDLC 513
 
42
#endif
 
43
 
 
44
#ifndef ARPHRD_LAPB
 
45
#warning "No definition of ARPHRD_HDLC in <net/if_arp.h>, using private value 516"
 
46
#define ARPHRD_LAPB 516
 
47
#endif
 
48
 
 
49
struct hwtype hdlc_hwtype =
 
50
{
 
51
    "hdlc", NULL, /*"(Cisco) HDLC", */ ARPHRD_HDLC, 0,
 
52
    NULL, NULL, NULL, 0
 
53
};
 
54
struct hwtype lapb_hwtype =
 
55
{
 
56
    "lapb", NULL, /*"LAPB", */ ARPHRD_LAPB, 0,
 
57
    NULL, NULL, NULL, 0
 
58
};
 
59
 
 
60
#endif                          /* HAVE_HWHDLCLAPB */