Replace the Webserver demo's uIP with the latest code ripped from the Contiki project...
[pub/USBasp.git] / Projects / Webserver / Lib / DHCPApp.c
index a687586..2aad7a6 100644 (file)
@@ -75,7 +75,7 @@ void DHCPApp_Callback(void)
                case DHCP_STATE_SendDiscover:\r
                        /* Clear all DHCP settings, reset client IP address */\r
                        memset(&AppState->DHCPOffer_Data, 0x00, sizeof(AppState->DHCPOffer_Data));\r
-                       uip_sethostaddr(&AppState->DHCPOffer_Data.AllocatedIP);\r
+                       uip_sethostaddr((uip_ipaddr_t*)&AppState->DHCPOffer_Data.AllocatedIP);\r
 \r
                        /* Fill out the DHCP response header */\r
                        AppDataSize += DHCPApp_FillDHCPHeader(AppData, DHCP_DISCOVER, AppState);\r
@@ -155,9 +155,9 @@ void DHCPApp_Callback(void)
                            (RequestResponse_MessageType == DHCP_ACK))\r
                        {\r
                                /* Set the new network parameters from the DHCP server */\r
-                               uip_sethostaddr(&AppState->DHCPOffer_Data.AllocatedIP);\r
-                               uip_setnetmask(&AppState->DHCPOffer_Data.Netmask);\r
-                               uip_setdraddr(&AppState->DHCPOffer_Data.GatewayIP);\r
+                               uip_sethostaddr((uip_ipaddr_t*)&AppState->DHCPOffer_Data.AllocatedIP);\r
+                               uip_setnetmask((uip_ipaddr_t*)&AppState->DHCPOffer_Data.Netmask);\r
+                               uip_setdraddr((uip_ipaddr_t*)&AppState->DHCPOffer_Data.GatewayIP);\r
                        \r
                                AppState->CurrentState = DHCP_STATE_AddressLeased;\r
                        }\r