2
0
mirror of https://gitlab.isc.org/isc-projects/dhcp synced 2025-08-31 06:15:55 +00:00

Support new struct hardware.

This commit is contained in:
Ted Lemon
2000-01-05 18:17:10 +00:00
parent 2cbc0e484d
commit 9e9b2261b1
4 changed files with 449 additions and 230 deletions

View File

@@ -22,7 +22,7 @@
#ifndef lint
static char ocopyright[] =
"$Id: dhcrelay.c,v 1.36 1999/10/28 13:09:35 mellon Exp $ Copyright (c) 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
"$Id: dhcrelay.c,v 1.37 2000/01/05 18:11:53 mellon Exp $ Copyright (c) 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -336,11 +336,9 @@ void relay (ip, packet, length, from_port, from, hfrom)
to.sin_len = sizeof to;
#endif
memcpy (hto.haddr, packet -> chaddr,
(packet -> hlen > sizeof hto.haddr
? sizeof hto.haddr
: packet -> hlen));
hto.htype = packet -> htype;
memcpy (&hto.hbuf [1], packet -> chaddr, packet -> hlen);
hto.hbuf [0] = packet -> htype;
hto.hlen = packet -> hlen + 1;
/* Wipe out the agent relay options and, if possible, figure
out which interface to use based on the contents of the