Lab2_web / Mbed 2 deprecated webserverBlinky

Dependencies:   mbed

Fork of webserverBlinky by RealTimeCompLab2

Revision:
99:3f56162e703e
Parent:
98:3babad0d1bd4
Child:
100:3f3a017684c5
--- a/main.cpp	Sat Jul 29 23:28:19 2017 +0000
+++ b/main.cpp	Sun Jul 30 01:49:56 2017 +0000
@@ -557,7 +557,8 @@
     ppp.httpPageCount++; // increment the number of frames we have made
 
     httpGetRoot = strncmp(dataStart, "GET / HTTP/1.", 13); // found GET, respond to both HTTP/1.<anything>
-    xFetch = strncmp(dataStart, "GET /x HTTP/1.", 14); // found GET /x , respond to both HTTP/1.<anything>
+    xFetch = strncmp(dataStart, "GET /x", 6); // found GET /x , respond to both HTTP/1.<anything>
+    // for example, in linux, xFetch can be used as:   echo GET /x | nc 172.10.10.2
     if( (httpGetRoot==0) || (xFetch==0) ) {
         n=n+sprintf(n+dataStart,"HTTP/1.1 200 OK\r\nServer: mbed-PPP-Blinky\r\n"); // 200 OK header
     } else {