- fixed msg_type
git-svn-id: http://moon:8086/svn/mips@221 a8ebac50-d88d-4704-bea3-6648445a41b3
This commit is contained in:
@@ -18,7 +18,7 @@ const char hostname[] = "ml402";
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
// Testing
|
||||
void DHCP_request_send(packet_t *pPacket, uint32_t dhcp_msg_type, uint8_t *mac_addr_src, uint8_t *inet_addr_src, uint8_t *inet_addr_dst, DHCP *pLast)
|
||||
void DHCP_request_send(packet_t *pPacket, uint8_t dhcp_msg_type, uint8_t *mac_addr_src, uint8_t *inet_addr_src, uint8_t *inet_addr_dst, DHCP *pLast)
|
||||
{
|
||||
DHCP dhcp;
|
||||
uint32_t size;
|
||||
@@ -41,8 +41,7 @@ void DHCP_request_send(packet_t *pPacket, uint32_t dhcp_msg_type, uint8_t *mac_a
|
||||
option_list_init(&options, pDHCP->options, sizeof(dhcp_option_t));
|
||||
|
||||
// Set msg type
|
||||
size = data_entry_create(buffer, TYPE_HW_ETH10, &dhcp_msg_type, 1);
|
||||
option_list_append(&options, DHCP_OPT_MSGTYPE, buffer, size);
|
||||
option_list_append(&options, DHCP_OPT_MSGTYPE, &dhcp_msg_type, 1);
|
||||
|
||||
#ifdef WITH_CLIENT_ID
|
||||
// Set client ID
|
||||
|
||||
@@ -69,7 +69,7 @@ typedef struct _soption_list_t
|
||||
#define DHCP_MSG_DHCPRELEASE 7
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
void DHCP_request_send(packet_t *pPacket, uint32_t dhcp_msg_type, uint8_t *mac_addr_src, uint8_t *inet_addr_src, uint8_t *inet_addr_dst, DHCP *pLast);
|
||||
void DHCP_request_send(packet_t *pPacket, uint8_t dhcp_msg_type, uint8_t *mac_addr_src, uint8_t *inet_addr_src, uint8_t *inet_addr_dst, DHCP *pLast);
|
||||
void option_list_init(option_list_t *pObj, void *pBuffer, size_t size);
|
||||
void option_list_append(option_list_t *pObj, uint8_t option_type, void const *pData, size_t size);
|
||||
size_t data_entry_create(void *pDst, uint8_t type, void const *pData, size_t size);
|
||||
|
||||
Reference in New Issue
Block a user