Fixed NULL value exception when there's no active port (#8)