can someone explain me how the TcpListener socket is waiting a connection by this
sf::TcpListener server;
server.listen(5000); // listens on port 5000
sf::TcpSocket socket;
server.accept(socket); // how does the server wait by doing this and accept automatically when a tcpsocket is attempting to connect to port 5000
i just want to understand it
https://github.com/SFML/SFML/blob/master/examples/sockets/TCP.cppafter i read this, i realized that i really did something wrong