trim trailing whitespace.