Skip to content

Commit

Permalink
Merge pull request #63 from nextcloud/sabre-xml-132
Browse files Browse the repository at this point in the history
Prevent infinite loop in sabre/xml
  • Loading branch information
MorrisJobke committed Aug 22, 2017
2 parents 4b60f9e + 06f6a06 commit 8b3251a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions patches.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ Patches:
- SabreDAV: Make sure that files that are children of directories, are reported as files https://github.com/fruux/sabre-dav/issues/982
- SabreXML: Fix invalid PHP docs https://github.com/fruux/sabre-xml/pull/128
- php-opencloud: Fix invalid PHP docs https://github.com/rackspace/php-opencloud/pull/711
- SabreXML: Prevent infinite loops for empty props element https://github.com/fruux/sabre-xml/pull/132
4 changes: 3 additions & 1 deletion sabre/xml/lib/Deserializer/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ function keyValue(Reader $reader, $namespace = null) {
$values[$clark] = $reader->parseCurrentElement()['value'];
}
} else {
$reader->read();
if (!$reader->read()) {
break;
}
}
} while ($reader->nodeType !== Reader::END_ELEMENT);

Expand Down

0 comments on commit 8b3251a

Please sign in to comment.