Need to add a check to this section to make sure that the debug port is valid.