--- a/wp/wp-includes/SimplePie/Locator.php Wed Sep 21 18:19:35 2022 +0200
+++ b/wp/wp-includes/SimplePie/Locator.php Tue Sep 27 16:37:53 2022 +0200
@@ -64,6 +64,7 @@
var $max_checked_feeds = 10;
var $force_fsockopen = false;
var $curl_options = array();
+ var $dom;
protected $registry;
public function __construct(SimplePie_File $file, $timeout = 10, $useragent = null, $max_checked_feeds = 10, $force_fsockopen = false, $curl_options = array())
@@ -75,12 +76,19 @@
$this->force_fsockopen = $force_fsockopen;
$this->curl_options = $curl_options;
- if (class_exists('DOMDocument'))
+ if (class_exists('DOMDocument') && $this->file->body != '')
{
$this->dom = new DOMDocument();
set_error_handler(array('SimplePie_Misc', 'silence_errors'));
- $this->dom->loadHTML($this->file->body);
+ try
+ {
+ $this->dom->loadHTML($this->file->body);
+ }
+ catch (Throwable $ex)
+ {
+ $this->dom = null;
+ }
restore_error_handler();
}
else