fix port parsing on windows