fix clean up - pointed to wrong character