Self-review plus fix memory leak.