Sfoglia il codice sorgente

[http_server]fix bug recieve POST request

balbekova 6 anni fa
parent
commit
66de9a48ef
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 2 2
      modules/HTTP_Server/http_server.c

+ 2 - 2
modules/HTTP_Server/http_server.c

@@ -1759,7 +1759,7 @@ char* AuthenticatedTrueRoutine(uint16_t* sendLen)
         }
         return 0;
     }
-    else if (strncmp(receiveBuf, "POST /settings.cgi", 18) == 0)
+    else if (strncmp(receiveBuf, "POST /settings.cgi", 18) == 0 || DataFlag2 >= 1)
     {
         if (seclevel == 0) 
         {
@@ -1829,7 +1829,7 @@ char* AuthenticatedTrueRoutine(uint16_t* sendLen)
             return sendBuf;
         }
     }
-    else if (strncmp(receiveBuf, "POST /info.cgi", 14) == 0)
+    else if (strncmp(receiveBuf, "POST /info.cgi", 14) == 0 || DataFlag >= 1)
     {
 		DataOffset = 0;
 		// POST Packet received