]> git.sesse.net Git - cubemap/blobdiff - httpinput.cpp
Correct the README and man page files for removed information.
[cubemap] / httpinput.cpp
index c975a2497007c1d45605ce73103f5405be4c78ed..478356ef75c4aac7e276a6e4db20189d9ad2a3cc 100644 (file)
@@ -79,13 +79,6 @@ HTTPInput::HTTPInput(const InputProto &serialized)
        string protocol;
        parse_url(url, &protocol, &host, &port, &path);  // Don't care if it fails.
 
-       // Older versions stored the extra \r\n in the HTTP header.
-       // Strip it if we find it.
-       if (http_header.size() >= 4 &&
-           memcmp(http_header.data() + http_header.size() - 4, "\r\n\r\n", 4) == 0) {
-               http_header.resize(http_header.size() - 2);
-       }
-
        pthread_mutex_init(&stats_mutex, NULL);
        stats.url = url;
        stats.bytes_received = serialized.bytes_received();
@@ -101,6 +94,7 @@ void HTTPInput::close_socket()
 {
        if (sock != -1) {
                safe_close(sock);
+               sock = -1;
        }
 
        MutexLock lock(&stats_mutex);