Small memleak fixes.