The program is huge.. so, I'm just pasting a very small part of it.
Case 1:
sf::TcpListener listener;
listener.listen(2001);
sf::TcpSocket socket;
std::cout<<"done1\n";
Case 2:
sf::TcpListener listener;
listener.listen(2001);
sf::TcpSocket socket;
std::cout<<"done1\n";
listener.accept(socket);
std::cout<<"done2\n";
Output for :
Case 1:
done1
Output for Case 2:
done1
done2 does not come in the output. and the program crashes.
Can somebody please tell me what might be going wrong, or where I should look for, for the the error?
Thanks in advance.