fix memleak bugs