Data Link Provider Interface (DLPI) network interface code. */
/*
- * Copyright (c) 1996-2000 Internet Software Consortium.
+ * Copyright (c) 1996-2001 Internet Software Consortium.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* This software was written for the Internet Software Consortium
* by Eric James Negaard, <lmdejn@lmd.ericsson.se>. To learn more about
* the Internet Software Consortium, see ``http://www.isc.org''.
+ *
+ * Joost Mulders has also done considerable work in debugging the DLPI API
+ * support on Solaris and getting this code to work properly on a variety
+ * of different Solaris platforms.
*/
/*
#ifndef lint
static char copyright[] =
-"$Id: dlpi.c,v 1.27 2001/03/16 22:12:18 tamino Exp $ Copyright (c) 1996-2000 The Internet Software Consortium. All rights reserved.\n";
+"$Id: dlpi.c,v 1.28 2001/04/05 20:53:01 mellon Exp $ Copyright (c) 1996-2000 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
/* Copy sender info */
if (saddr) {
- memcpy (saddr, &buf [dlp -> unitdata_ind.dl_src_addr_offset],
+ memcpy (saddr,
+ (char *)buf + dlp -> unitdata_ind.dl_src_addr_offset,
dlp -> unitdata_ind.dl_src_addr_length);
}
if (saddrlen) {
/* Copy destination info */
if (daddr) {
- memcpy (daddr, &buf [dlp -> unitdata_ind.dl_dest_addr_offset],
+ memcpy (daddr,
+ (char *)buf + dlp -> unitdata_ind.dl_dest_addr_offset,
dlp -> unitdata_ind.dl_dest_addr_length);
}
if (daddrlen) {