From 97f843e93b97422eb8a2204de973f7208a3c454c Mon Sep 17 00:00:00 2001 From: Platonides Date: Fri, 4 Mar 2011 22:52:20 +0000 Subject: [PATCH] If the unknown element is empty, there won't be a matching END_ELEMENT. There's nothing to peek inside. --- includes/media/SVGMetadataExtractor.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/includes/media/SVGMetadataExtractor.php b/includes/media/SVGMetadataExtractor.php index 7253a06ccd..967d671fb4 100644 --- a/includes/media/SVGMetadataExtractor.php +++ b/includes/media/SVGMetadataExtractor.php @@ -161,10 +161,13 @@ class SVGReader { * @param String $name of the element that we are reading from */ private function animateFilter( $name ) { - $this->debug ( "animate filter" ); + $this->debug ( "animate filter for tag $name" ); if( $this->reader->nodeType != XmlReader::ELEMENT ) { return; } + if ( $this->reader->isEmptyElement ) { + return; + } $exitDepth = $this->reader->depth; $keepReading = $this->reader->read(); while( $keepReading ) { -- 2.20.1