]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
replace ARPHRD with HTYPE
authorTed Lemon <source@isc.org>
Fri, 8 Nov 1996 20:09:41 +0000 (20:09 +0000)
committerTed Lemon <source@isc.org>
Fri, 8 Nov 1996 20:09:41 +0000 (20:09 +0000)
cf/linux.h
common/dispatch.c
confpars.c
dhcp.h
dispatch.c
includes/cf/linux.h
includes/dhcp.h
server/confpars.c

index 0674727bc592efd9f5c56ff3cf8e9218c0b4cc53..8e439d0b745030cd80fe296da8b3100fb5947403 100644 (file)
@@ -61,9 +61,6 @@ extern int h_errno;
 
 #include <net/if.h>
 
-#define ARPHRD_ETHER   1
-#define        ARPHRD_IEEE802  6
-
 #include <sys/time.h>          /* gettimeofday()*/
 #include <linux/time.h>                /* also necessary */
 
index c5b33dad35b31b8f7cd603f907431f5f6342824b..1985fb4e99419cda151e9572bdcd31592477a534 100644 (file)
@@ -42,7 +42,7 @@
 
 #ifndef lint
 static char copyright[] =
-"$Id: dispatch.c,v 1.26 1996/09/11 18:53:33 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
+"$Id: dispatch.c,v 1.27 1996/11/08 20:06:29 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
 #endif /* not lint */
 
 #include "dhcpd.h"
@@ -153,7 +153,7 @@ void discover_interfaces (serverP)
                        struct sockaddr_dl *foo = ((struct sockaddr_dl *)
                                                   (&ifp -> ifr_addr));
                        tmp -> hw_address.hlen = foo -> sdl_alen;
-                       tmp -> hw_address.htype = ARPHRD_ETHER; /* XXX */
+                       tmp -> hw_address.htype = HTYPE_ETHER; /* XXX */
                        memcpy (tmp -> hw_address.haddr,
                                LLADDR (foo), foo -> sdl_alen);
                } else
index 06c4692d2ea4d095c08b920d6890e1a5f9a6d83c..76e8606aa84bf6e4ac818367ba8b90f49e917920 100644 (file)
@@ -42,7 +42,7 @@
 
 #ifndef lint
 static char copyright[] =
-"$Id: confpars.c,v 1.35 1996/09/13 18:58:20 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
+"$Id: confpars.c,v 1.36 1996/11/08 20:06:28 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
 #endif /* not lint */
 
 #include "dhcpd.h"
@@ -289,7 +289,6 @@ int parse_statement (cfile, group, type, host_decl, declaration)
                if (type == HOST_DECL)
                        parse_warn ("get-lease-hostnames not allowed here.");
                group -> get_lease_hostnames = parse_boolean (cfile);
-note ("get_lease_hostnames: %d", group -> get_lease_hostnames);
                break;
 
              case USE_HOST_DECL_NAMES:
@@ -866,13 +865,11 @@ void parse_hardware_param (cfile, hardware)
        token = next_token (&val, cfile);
        switch (token) {
              case ETHERNET:
-               hardware -> htype = ARPHRD_ETHER;
+               hardware -> htype = HTYPE_ETHER;
                break;
-#ifdef ARPHRD_IEEE802 /* XXX */
              case TOKEN_RING:
-               hardware -> htype = ARPHRD_IEEE802;
+               hardware -> htype = HTYPE_IEEE802;
                break;
-#endif
              default:
                parse_warn ("expecting a network hardware type");
                skip_to_semi (cfile);
diff --git a/dhcp.h b/dhcp.h
index a4c04821cf20abc039598e7e32a65f59f8ed6f9c..23a8bf7377ca9de8615e637338c642a842245c97 100644 (file)
--- a/dhcp.h
+++ b/dhcp.h
@@ -80,6 +80,10 @@ struct dhcp_packet {
 /* Possible values for flags field... */
 #define BOOTP_BROADCAST 32768L
 
+/* Possible values for hardware type (htype) field... */
+#define HTYPE_ETHER    1               /* Ethernet 10Mbps              */
+#define HTYPE_IEEE802  6               /* IEEE 802.2 Token Ring...     */
+
 /* Magic cookie validating dhcp options field (and bootp vendor
    extensions field). */
 #define DHCP_OPTIONS_COOKIE    "\143\202\123\143"
index c5b33dad35b31b8f7cd603f907431f5f6342824b..1985fb4e99419cda151e9572bdcd31592477a534 100644 (file)
@@ -42,7 +42,7 @@
 
 #ifndef lint
 static char copyright[] =
-"$Id: dispatch.c,v 1.26 1996/09/11 18:53:33 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
+"$Id: dispatch.c,v 1.27 1996/11/08 20:06:29 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
 #endif /* not lint */
 
 #include "dhcpd.h"
@@ -153,7 +153,7 @@ void discover_interfaces (serverP)
                        struct sockaddr_dl *foo = ((struct sockaddr_dl *)
                                                   (&ifp -> ifr_addr));
                        tmp -> hw_address.hlen = foo -> sdl_alen;
-                       tmp -> hw_address.htype = ARPHRD_ETHER; /* XXX */
+                       tmp -> hw_address.htype = HTYPE_ETHER; /* XXX */
                        memcpy (tmp -> hw_address.haddr,
                                LLADDR (foo), foo -> sdl_alen);
                } else
index 0674727bc592efd9f5c56ff3cf8e9218c0b4cc53..8e439d0b745030cd80fe296da8b3100fb5947403 100644 (file)
@@ -61,9 +61,6 @@ extern int h_errno;
 
 #include <net/if.h>
 
-#define ARPHRD_ETHER   1
-#define        ARPHRD_IEEE802  6
-
 #include <sys/time.h>          /* gettimeofday()*/
 #include <linux/time.h>                /* also necessary */
 
index a4c04821cf20abc039598e7e32a65f59f8ed6f9c..23a8bf7377ca9de8615e637338c642a842245c97 100644 (file)
@@ -80,6 +80,10 @@ struct dhcp_packet {
 /* Possible values for flags field... */
 #define BOOTP_BROADCAST 32768L
 
+/* Possible values for hardware type (htype) field... */
+#define HTYPE_ETHER    1               /* Ethernet 10Mbps              */
+#define HTYPE_IEEE802  6               /* IEEE 802.2 Token Ring...     */
+
 /* Magic cookie validating dhcp options field (and bootp vendor
    extensions field). */
 #define DHCP_OPTIONS_COOKIE    "\143\202\123\143"
index 06c4692d2ea4d095c08b920d6890e1a5f9a6d83c..76e8606aa84bf6e4ac818367ba8b90f49e917920 100644 (file)
@@ -42,7 +42,7 @@
 
 #ifndef lint
 static char copyright[] =
-"$Id: confpars.c,v 1.35 1996/09/13 18:58:20 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
+"$Id: confpars.c,v 1.36 1996/11/08 20:06:28 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium.  All rights reserved.\n";
 #endif /* not lint */
 
 #include "dhcpd.h"
@@ -289,7 +289,6 @@ int parse_statement (cfile, group, type, host_decl, declaration)
                if (type == HOST_DECL)
                        parse_warn ("get-lease-hostnames not allowed here.");
                group -> get_lease_hostnames = parse_boolean (cfile);
-note ("get_lease_hostnames: %d", group -> get_lease_hostnames);
                break;
 
              case USE_HOST_DECL_NAMES:
@@ -866,13 +865,11 @@ void parse_hardware_param (cfile, hardware)
        token = next_token (&val, cfile);
        switch (token) {
              case ETHERNET:
-               hardware -> htype = ARPHRD_ETHER;
+               hardware -> htype = HTYPE_ETHER;
                break;
-#ifdef ARPHRD_IEEE802 /* XXX */
              case TOKEN_RING:
-               hardware -> htype = ARPHRD_IEEE802;
+               hardware -> htype = HTYPE_IEEE802;
                break;
-#endif
              default:
                parse_warn ("expecting a network hardware type");
                skip_to_semi (cfile);