Merge "Do not return pointer to freed memory"