fix port reading
Merge pull request #3 from whodidthis/master

Fix reading port