convert port to int