Fix missing \r after Connection:keep-alive header in HTTP requests

This commit is contained in:
Fred Nicolson 2018-11-26 16:40:18 +00:00
parent dd1322385b
commit 87f8ee21b1

View File

@ -142,7 +142,7 @@ namespace fr
//Add in required headers if they're missing //Add in required headers if they're missing
if(header_data.find("Connection") == header_data.end()) if(header_data.find("Connection") == header_data.end())
request += "Connection: keep-alive\n"; request += "Connection: keep-alive\r\n";
if(header_data.find("Host") == header_data.end()) if(header_data.find("Host") == header_data.end())
request += "Host: " + host + "\r\n"; request += "Host: " + host + "\r\n";
if(!body.empty()) if(!body.empty())