Trim trailing lines.