feat: shbc configuration

This commit is contained in:
Mudit Vats
2021-08-05 10:54:18 -07:00
parent f0682c4588
commit e0fe219646
12 changed files with 354 additions and 5 deletions

13
lms.cpp
View File

@@ -15,13 +15,22 @@
#include <netdb.h>
#endif
SOCKET lms_connect()
SOCKET lms_connect(bool securePort)
{
std::string lmsAddress = "localhost";
std::string lmsPort = "16992";
std::string lmsPort;
SOCKET s = INVALID_SOCKET;
struct addrinfo *addr, hints;
if (securePort)
{
lmsPort = "16993";
}
else
{
lmsPort = "16992";
}
#ifdef _WIN32
WSADATA wsa;
if (WSAStartup(MAKEWORD(2, 2), &wsa) != 0)