From ff1d1a7a4d2c020f647000070ea73791f7073c43 Mon Sep 17 00:00:00 2001 From: Michael M Date: Sun, 6 Aug 2017 23:45:39 -0700 Subject: [PATCH] UPnP: use std::to_string --- Source/Core/Common/UPnP.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Source/Core/Common/UPnP.cpp b/Source/Core/Common/UPnP.cpp index cb4a51574c..bedecf9a43 100644 --- a/Source/Core/Common/UPnP.cpp +++ b/Source/Core/Common/UPnP.cpp @@ -7,15 +7,16 @@ #include "Common/UPnP.h" #include "Common/Logging/Log.h" -#include "Common/StringUtil.h" #include +#include #include #include #include #include #include #include +#include static UPNPUrls s_urls; static IGDdatas s_data; @@ -108,7 +109,7 @@ static bool InitUPnP() // -- static bool UnmapPort(const u16 port) { - std::string port_str = StringFromFormat("%d", port); + std::string port_str = std::to_string(port); UPNP_DeletePortMapping(s_urls.controlURL, s_data.first.servicetype, port_str.c_str(), "UDP", nullptr); @@ -122,7 +123,7 @@ static bool MapPort(const char* addr, const u16 port) if (s_mapped > 0) UnmapPort(s_mapped); - std::string port_str = StringFromFormat("%d", port); + std::string port_str = std::to_string(port); int result = UPNP_AddPortMapping( s_urls.controlURL, s_data.first.servicetype, port_str.c_str(), port_str.c_str(), addr, (std::string("dolphin-emu UDP on ") + addr).c_str(), "UDP", nullptr, nullptr);