fix save clobbering bug