Fixed string corruption bug