#ifndef lint
static char ocopyright[] =
-"$Id: dhclient.c,v 1.65 1999/03/26 21:27:23 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
+"$Id: dhclient.c,v 1.66 1999/03/29 18:49:58 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
client -> packet.hops = 0;
client -> packet.xid = random ();
client -> packet.secs = 0; /* filled in by send_discover. */
+
+ if (can_receive_unicast_unconfigured (client -> interface))
+ client -> packet.flags = 0;
+ else
+ client -> packet.flags = htons (BOOTP_BROADCAST);
+
memset (&(client -> packet.ciaddr),
0, sizeof client -> packet.ciaddr);
memset (&(client -> packet.yiaddr),
client -> packet.hops = 0;
client -> packet.xid = client -> xid;
client -> packet.secs = 0; /* Filled in by send_request. */
- if (can_receive_unicast_unconfigured (client -> interface))
- client -> packet.flags = 0;
- else
- client -> packet.flags = htons (BOOTP_BROADCAST);
/* If we own the address we're requesting, put it in ciaddr;
otherwise set ciaddr to zero. */
} else {
memset (&client -> packet.ciaddr, 0,
sizeof client -> packet.ciaddr);
+ if (can_receive_unicast_unconfigured (client -> interface))
+ client -> packet.flags = 0;
+ else
+ client -> packet.flags = htons (BOOTP_BROADCAST);
}
memset (&client -> packet.yiaddr, 0,