Memory bugs

I just found two more memory bugs.