Turn a leaked object into a stack variable instead.
Again revert r222044 to resolve darwin objc test fails.