Merge "Replace splitlines() with something more tolerant."