Added bounds checking for listening_ports.

Needs to be a valid TCP port number, and not less than 1 or greater than 65535