Ensure HTTP request variables lives till it is used (#7744)

Solves https://www.reddit.com/r/openrct2/comments/8uftdh/
This commit is contained in:
Michał Janiszewski 2018-06-28 22:23:21 +02:00 committed by GitHub
parent fe76c807aa
commit 13224104e4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -101,10 +101,10 @@ Response Do(const Request & req)
std::runtime_error("Failed to initialize curl");
Response res;
WriteThis wt;
if (req.method == Method::POST || req.method == Method::PUT)
{
WriteThis wt;
wt.readptr = req.body.c_str();
wt.sizeleft = req.body.size();