Disable uIP connection polling for now - this seems to corrupt the buffers.
[pub/USBasp.git] / Projects / Webserver / Lib / HTTPServerApp.c
index 9a70dad..635a307 100644 (file)
@@ -199,7 +199,6 @@ static void HTTPServerApp_SendResponseHeader(void)
        char*               const AppData     = (char*)uip_appdata;\r
 \r
        char*    HeaderToSend;\r
-       uint16_t HeaderLength;\r
 \r
        /* Determine which HTTP header should be sent to the client */\r
        if (AppState->HTTPServer.FileOpen)\r
@@ -214,9 +213,8 @@ static void HTTPServerApp_SendResponseHeader(void)
        }\r
 \r
        /* Copy over the HTTP response header and send it to the receiving client */\r
-       HeaderLength = strlen_P(HeaderToSend);\r
-       strncpy_P(AppData, HeaderToSend, HeaderLength);\r
-       uip_send(AppData, HeaderLength);\r
+       strcpy_P(AppData, HeaderToSend);\r
+       uip_send(AppData, strlen(AppData));\r
 }\r
 \r
 /** HTTP Server State handler for the MIME Header Send state. This state manages the transmission of the file\r