diff options
author | Leonard Richardson <leonardr@segfault.org> | 2012-07-02 16:10:06 -0400 |
---|---|---|
committer | Leonard Richardson <leonardr@segfault.org> | 2012-07-02 16:10:06 -0400 |
commit | 23329a21c2a00c312f024579cb47040f737cb6fe (patch) | |
tree | 200ed50ba44483c2a172b207c67e55d8e4f040ec | |
parent | 7b17371e76d75af684466e2d13745b683b864f5b (diff) |
Fixed a typo that made parsing much slower than it should have been. [bug=1020268]
-rw-r--r-- | NEWS.txt | 8 | ||||
-rw-r--r-- | bs4/__init__.py | 2 |
2 files changed, 8 insertions, 2 deletions
@@ -1,9 +1,15 @@ = 4.1.1 (Unreleased) = -Fixed an html5lib tree builder crash which happened when html5lib +* Fixed an html5lib tree builder crash which happened when html5lib moved a tag with a multivalued attribute from one part of the tree to another. [bug=1019603] +* Correctly handle closing tags with an XML namespace declared. Patch + by Andreas Kostyrka. [bug=1019635] + +* Fixed a typo that made parsing significantly slower than it should + have been. [bug=1020268] + = 4.1.0 (20120529) = * Added experimental support for fixing Windows-1252 characters diff --git a/bs4/__init__.py b/bs4/__init__.py index af8c718..0e59a33 100644 --- a/bs4/__init__.py +++ b/bs4/__init__.py @@ -267,7 +267,7 @@ class BeautifulSoup(Tag): for i in range(len(self.tagStack) - 1, 0, -1): if (name == self.tagStack[i].name - and nsprefix == self.tagStack[i].nsprefix == nsprefix): + and nsprefix == self.tagStack[i].prefix): numPops = len(self.tagStack) - i break if not inclusivePop: |