Memory leak fixes
Memory leak fixes