LP#1691563: Prevent "Use of freed value in iteration" error during adjust to zero