Fix some memory leak