Fix non-critical memory leak