Fix payload iteration issue of FormBody; Log form body; ignore body for response of HEAD.
This commit is contained in:
@@ -3,6 +3,8 @@
|
||||
|
||||
#include <string>
|
||||
|
||||
#include "webcc/globals.h"
|
||||
|
||||
namespace webcc {
|
||||
namespace utility {
|
||||
|
||||
@@ -22,6 +24,18 @@ std::string GetTimestamp();
|
||||
bool SplitKV(const std::string& str, char delimiter,
|
||||
std::string* key, std::string* value);
|
||||
|
||||
// Tell the size in bytes of the given file.
|
||||
// Return kInvalidLength (-1) on failure.
|
||||
std::size_t TellSize(const Path& path);
|
||||
|
||||
// Read entire file into string.
|
||||
bool ReadFile(const Path& path, std::string* output);
|
||||
|
||||
// Dump the string data line by line to achieve more readability.
|
||||
// Also limit the maximum size of the data to be dumped.
|
||||
void DumpByLine(const std::string& data, std::ostream& os,
|
||||
const std::string& prefix);
|
||||
|
||||
} // namespace utility
|
||||
} // namespace webcc
|
||||
|
||||
|
||||
Reference in New Issue
Block a user