Bug in port state saving