Fix variable shadowing that makes the previous fix ineffective.

The leak seems to only appear if we're out of memory, but that's when leaks matter the most. Future refactoring could also make the leak more likely, so let's zap it before it gets a chance.