fixed port connection bug