forked from mirrors/kolyah35-minecraft-pe-0.6.1
Android build issues fixed
(except i fixed the wrong stuff first...)
This commit is contained in:
parent
9fd54afd61
commit
76839dfbaa
6 changed files with 17 additions and 9 deletions
|
|
@ -5,6 +5,7 @@
|
|||
#include <cctype>
|
||||
#include <cstring>
|
||||
#include <string>
|
||||
#include <sstream>
|
||||
#include <vector>
|
||||
|
||||
#if defined(_WIN32)
|
||||
|
|
@ -176,7 +177,9 @@ bool resolveAndConnect(const std::string& host, int port, int& outSock) {
|
|||
hints.ai_family = AF_UNSPEC;
|
||||
hints.ai_socktype = SOCK_STREAM;
|
||||
|
||||
const std::string portStr = std::to_string(port);
|
||||
std::ostringstream portStream;
|
||||
portStream << port;
|
||||
const std::string portStr = portStream.str();
|
||||
if (getaddrinfo(host.c_str(), portStr.c_str(), &hints, &result) != 0)
|
||||
return false;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue