mirror of
https://github.com/RPCS3/rpcs3.git
synced 2026-07-11 01:24:54 +02:00
Add user agent to curl requests
This commit is contained in:
@@ -24,29 +24,27 @@ namespace utils
|
||||
return (m_hi << 24) | (m_mid << 16) | (m_lo << 8) | ((uint(m_type) & 0xf) << 4) | (m_type_index & 0xf);
|
||||
}
|
||||
|
||||
std::string version::to_string() const
|
||||
std::string version::to_string(bool simple) const
|
||||
{
|
||||
std::string version = std::to_string(hi()) + "." + std::to_string(mid());
|
||||
std::string version = fmt::format("%d.%d", hi(), mid());
|
||||
|
||||
if (lo())
|
||||
{
|
||||
version += '.';
|
||||
version += std::to_string(lo());
|
||||
fmt::append(version, ".%d", lo());
|
||||
}
|
||||
|
||||
if (type() != version_type::release)
|
||||
if (!simple && type() != version_type::release)
|
||||
{
|
||||
if (!postfix().empty())
|
||||
{
|
||||
version += "-" + postfix();
|
||||
fmt::append(version, "-%s", postfix());
|
||||
}
|
||||
|
||||
version += ' ';
|
||||
version += utils::to_string(type());
|
||||
fmt::append(version, " %s", utils::to_string(type()));
|
||||
|
||||
if (type_index() > 1)
|
||||
{
|
||||
version += " " + std::to_string(type_index());
|
||||
fmt::append(version, " %d", type_index());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user