]> git.mxchange.org Git - simgear.git/commitdiff
Whoops, fix tests for user-agent being HTTP/1.1 spec
authorJames Turner <zakalawe@mac.com>
Thu, 4 Aug 2011 18:37:30 +0000 (19:37 +0100)
committerJames Turner <zakalawe@mac.com>
Thu, 4 Aug 2011 18:37:30 +0000 (19:37 +0100)
simgear/io/test_HTTP.cxx

index d0c771213902f58272fe7b04cb4d0d9c48173aa9..aa8138245bd221b6d95103daeccdb5de0149f9bb 100644 (file)
@@ -106,7 +106,7 @@ public:
         if (state == STATE_IDLE) {
             state = STATE_HEADERS;
             string_list line = strutils::split(buffer, NULL, 3);
-            if (line.size() < 4) {
+            if (line.size() < 3) {
                 cerr << "malformed request:" << buffer << endl;
                 exit(-1);
             }
@@ -114,7 +114,6 @@ public:
             method = line[0];
             path = line[1];
             httpVersion = line[2];
-            userAgent = line[3];
             requestHeaders.clear();
             buffer.clear();
         } else if (state == STATE_HEADERS) {
@@ -230,7 +229,6 @@ public:
     string method;
     string path;
     string httpVersion;
-    string userAgent;
     std::map<string, string> requestHeaders;
 };