Fix memory corruption through InitString and second-engine loading