X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/c088c3e07ab17e33165fa41fe6175a25bc03d4da..43e405c1473de38b677d9a228fea4df415037bb1:/projects/sgauthstress/main.cpp?ds=sidebyside diff --git a/projects/sgauthstress/main.cpp b/projects/sgauthstress/main.cpp index 21df6d74..c7e69c4a 100644 --- a/projects/sgauthstress/main.cpp +++ b/projects/sgauthstress/main.cpp @@ -98,7 +98,13 @@ SetSignalHandlers(); PROTO proto(settings.GetServerName(), settings.GetServerPort(), settings.GetLocalPort(), - 1); + 1000); + +if (!proto.Start()) + { + std::cerr << "Failed to start listening thread: '" << proto.GetStrError() << "'" << std::endl; + return -1; + } STORE_LOADER storeLoader(settings.GetModulesPath(), settings.GetStoreModuleSettings()); if (storeLoader.Load()) @@ -143,6 +149,8 @@ while (running) usleep(200000); } +proto.Stop(); + storeLoader.Unload(); return 0;