Trim input lines.