Add a missing header and remove an unused variable.

This commit is contained in:
Nicholas J. Kain 2010-12-26 15:06:16 -05:00
parent ea4041983d
commit 0f3d4598ad
2 changed files with 1 additions and 1 deletions

View File

@ -222,7 +222,6 @@ int get_raw_packet(struct dhcpMessage *payload, int fd)
{ {
struct ip_udp_dhcp_packet packet; struct ip_udp_dhcp_packet packet;
uint16_t check; uint16_t check;
const int header_size = sizeof(struct iphdr) + sizeof(struct udphdr);
const int packet_size = sizeof(struct ip_udp_dhcp_packet); const int packet_size = sizeof(struct ip_udp_dhcp_packet);
memset(&packet, 0, packet_size); memset(&packet, 0, packet_size);

View File

@ -26,6 +26,7 @@
#include <sys/ioctl.h> #include <sys/ioctl.h>
#include <netinet/in.h> #include <netinet/in.h>
#include <unistd.h> #include <unistd.h>
#include <fcntl.h>
#include <string.h> #include <string.h>
#include <arpa/inet.h> #include <arpa/inet.h>
#include <net/if.h> #include <net/if.h>