I'm new to c++ and have to create class for handling sockets. This class has a method named listen() and in this method need calling listen function to socket (for example see below) but method listen hiding listen function how to solve it ?
void CTCPBlockingSocket::listen() {
listen(server_socket,5);
}
Use the ::
operator to specify you want the listen
name which is in the global scope, not in a class or namespace.
void CTCPBlockingSocket::listen() {
::listen(server_socket,5);
}