Plug a memory leak