임시저장
This commit is contained in:
@@ -42,6 +42,18 @@ int main() {
|
||||
|
||||
|
||||
Chattr::ThreadPool threadPool(3);
|
||||
/*int returnedIntager = 0;
|
||||
int passvalue = 2;
|
||||
threadPool.enqueueJob([](int& i){
|
||||
spdlog::info("JobTest");
|
||||
if (i == 2) {
|
||||
i = 1;
|
||||
return 2;
|
||||
}
|
||||
return 1;
|
||||
}, returnedIntager, std::ref(passvalue));
|
||||
|
||||
Sleep(1000);*/
|
||||
|
||||
while (true) {
|
||||
spdlog::info("Waiting for connection...");
|
||||
@@ -49,8 +61,8 @@ int main() {
|
||||
|
||||
threadPool.enqueueJob(_TCPClient, std::move(clientSock), clientAddr);
|
||||
|
||||
//Chattr::Thread thread_(_TCPClient, std::move(clientSock), clientAddr);
|
||||
//thread_.detach();
|
||||
Chattr::Thread thread_(_TCPClient, std::move(clientSock), clientAddr);
|
||||
thread_.detach();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user