Trying to roll my own port fix