BaseSgmlLinkExtractor: Fixed unknown_endtag() so that it only set current_link=None when the end tag match the opening tag

This commit is contained in:
Benoit Blanchon 2013-12-07 19:47:50 +01:00 committed by Daniel Graña
parent 76c7e200aa
commit 7e4d62778e
1 changed files with 2 additions and 1 deletions

View File

@ -74,7 +74,8 @@ class BaseSgmlLinkExtractor(FixedSGMLParser):
self.current_link = link
def unknown_endtag(self, tag):
self.current_link = None
if self.scan_tag(tag):
self.current_link = None
def handle_data(self, data):
if self.current_link: