Make port variable non-global.