Explicit computation of port number from string.