mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-26 05:55:51 +00:00
More work toward http/https client unification.
This commit is contained in:
@@ -39,7 +39,7 @@ Json::Value JSONRPCError(int code, const std::string& message)
|
||||
// and to be compatible with other JSON-RPC implementations.
|
||||
//
|
||||
|
||||
std::string createHTTPPost(const std::string& strPath, const std::string& strMsg, const std::map<std::string, std::string>& mapRequestHeaders)
|
||||
std::string createHTTPPost(const std::string& strHost, const std::string& strPath, const std::string& strMsg, const std::map<std::string, std::string>& mapRequestHeaders)
|
||||
{
|
||||
std::ostringstream s;
|
||||
|
||||
@@ -47,7 +47,7 @@ std::string createHTTPPost(const std::string& strPath, const std::string& strMsg
|
||||
<< (strPath.empty() ? "/" : strPath)
|
||||
<< " HTTP/1.1\r\n"
|
||||
<< "User-Agent: " SYSTEM_NAME "-json-rpc/" << FormatFullVersion() << "\r\n"
|
||||
<< "Host: 127.0.0.1\r\n"
|
||||
<< "Host: " << strHost << "\r\n"
|
||||
<< "Content-Type: application/json\r\n"
|
||||
<< "Content-Length: " << strMsg.size() << "\r\n"
|
||||
<< "Accept: application/json\r\n";
|
||||
|
||||
Reference in New Issue
Block a user