Explorar o código

htmlspecialchars_decode for all SIMPLEPIE_CONSTRUCT_MAYBE_HTML

https://github.com/FreshRSS/FreshRSS/issues/754
Alexandre Alapetite %!s(int64=11) %!d(string=hai) anos
pai
achega
0e08b5ba56
Modificáronse 1 ficheiros con 1 adicións e 5 borrados
  1. 1 5
      lib/SimplePie/SimplePie/Sanitize.php

+ 1 - 5
lib/SimplePie/SimplePie/Sanitize.php

@@ -249,11 +249,7 @@ class SimplePie_Sanitize
 		{
 			if ($type & SIMPLEPIE_CONSTRUCT_MAYBE_HTML)
 			{
-				if (preg_match('/&#(x[0-9a-fA-F]+|[0-9]+);/', $data))	//FreshRSS
-				{
-					$data = htmlspecialchars_decode($data, ENT_QUOTES);	//FreshRSS
-					//syslog(LOG_DEBUG, 'SimplePie sanitize MAYBE_HTML htmlspecialchars_decode: ' . $data);	//FreshRSS
-				}
+				$data = htmlspecialchars_decode($data, ENT_QUOTES);	//FreshRSS 
 				if (preg_match('/(&(#(x[0-9a-fA-F]+|[0-9]+)|[a-zA-Z0-9]+)|<\/[A-Za-z][^\x09\x0A\x0B\x0C\x0D\x20\x2F\x3E]*' . SIMPLEPIE_PCRE_HTML_ATTRIBUTE . '>)/', $data))
 				{
 					$type |= SIMPLEPIE_CONSTRUCT_HTML;