Fix memory leak.
Fixes, review application.