mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-15 05:47:56 -07:00
Core/NetPlayServer: Use fmt::format_to_n in GetInterfaceHost()
Lets us avoid some noisy deprecation warnings on macOS (and also lets us use a more generic formatting specifier).
This commit is contained in:
parent
2b877fc92b
commit
9abcc1c08b
@ -2294,8 +2294,9 @@ std::unordered_set<std::string> NetPlayServer::GetInterfaceSet() const
|
||||
// called from ---GUI--- thread
|
||||
std::string NetPlayServer::GetInterfaceHost(const std::string& inter) const
|
||||
{
|
||||
char buf[16];
|
||||
sprintf(buf, ":%d", GetPort());
|
||||
char buf[16]{};
|
||||
fmt::format_to_n(buf, sizeof(buf) - 1, ":{}", GetPort());
|
||||
|
||||
auto lst = GetInterfaceListInternal();
|
||||
for (const auto& list_entry : lst)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user