Added delete call after release to fix memory leak.