Merge branch 'hugo2'

+ changed the appropriate getters for client
+ moved the functions to parse the http message
  (first line, headers, and body)
  outside client, in parsing_http_message.cpp
+ resolved some of the throw problems
This commit is contained in:
hugogogo
2022-08-09 15:54:40 +02:00
24 changed files with 205391 additions and 214 deletions

View File

@@ -13,7 +13,7 @@ Where does cgi fit in in all this ???
*/
std::string path = client->get_path();
std::string path = client->get_rq_abs_path();
// this might not be the best thing, a voir
path.insert(0, client->assigned_location->root);
@@ -57,9 +57,15 @@ Where does cgi fit in in all this ???
// TMP HUGO
//
std::string script_output;
if (_is_cgi(client))
{
_exec_cgi(client);
script_output = _exec_cgi(client);
// DEBUG
std::cout << "\n____script_output____\n" << script_output << "\n_______________\n";
// wip check output of script
_check_script_output(client, script_output);
client->response += script_output;
return;
}
//