HomePhabricator

Don't abort on invalid characters when creating DOM

Description

Don't abort on invalid characters when creating DOM

This applies to errors like:

array (

0 =>
LibXMLError::__set_state(array(
  'level' => 2,
  'code' => 9,
  'column' => 47,
  'message' => 'Invalid char in CDATA 0x8

',

  'file' => NULL,
  'line' => 1,
)),

)

The character is removed, but this way we don't abort.

Bug: T92303
Bug: T106079
Change-Id: I1dc9bf0a3f639d3f2d943f7cf5c36e80a1dba297