changed: if there is no body we do not parse application/json to space

git-svn-id: svn://ttmath.org/publicrep/winix/trunk@1183 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
Tomasz Sowa 2019-03-25 00:51:51 +00:00
parent 4c2efc08fd
commit 177e58da4e
1 changed files with 14 additions and 7 deletions

View File

@ -1095,6 +1095,8 @@ void App::ReadPostJson()
}
while( read_len == buffer_len );
if( !post_buffer.empty() )
{
PT::JSONToSpaceParser::Status status = post_json_parser.ParseString(post_buffer.c_str());
post_buffer.clear();
@ -1105,6 +1107,11 @@ void App::ReadPostJson()
// return an error (http error of some kind?)
}
}
else
{
log << log3 << "App: input body empty (skipping parsing)" << logend;
}
}