Fix string deallocation faults