mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-02-10 16:23:05 +00:00
Make it just a bit more drop-in compatible.
This commit is contained in:
parent
e189ba42b0
commit
e569903f9c
13
net/url.h
13
net/url.h
@ -58,11 +58,20 @@ struct UrlEncoder
|
||||
Add(key, value ? "true" : "false");
|
||||
}
|
||||
|
||||
virtual void Finish()
|
||||
{
|
||||
}
|
||||
|
||||
const std::string &ToString() const
|
||||
{
|
||||
return data;
|
||||
}
|
||||
|
||||
virtual std::string GetMimeType() const
|
||||
{
|
||||
return "application/x-www-form-urlencoded";
|
||||
}
|
||||
|
||||
protected:
|
||||
template <typename T>
|
||||
void AddT(const std::string &key, const char *fmt, const T value)
|
||||
@ -142,12 +151,12 @@ struct MultipartFormDataEncoder : UrlEncoder
|
||||
data += "\r\n";
|
||||
}
|
||||
|
||||
void Finish()
|
||||
virtual void Finish()
|
||||
{
|
||||
data += "--" + boundary + "--";
|
||||
}
|
||||
|
||||
std::string GetMimeType() const
|
||||
virtual std::string GetMimeType() const
|
||||
{
|
||||
return "multipart/form-data; boundary=\"" + boundary + "\"";
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user