Removed unnecessary string copying from loop body.