Bug 525587 - Close tag missing in XML output of optionally empty tags
Close tag missing in XML output of optionally empty tags
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: perl-HTML-Tree (Show other bugs)
10
All Linux
high Severity high
: ---
: ---
Assigned To: Tom "spot" Callaway
Fedora Extras Quality Assurance
:
Depends On:
Blocks: 524832
  Show dependency treegraph
 
Reported: 2009-09-24 18:45 EDT by Jeff Fearn
Modified: 2009-10-27 12:22 EDT (History)
3 users (show)

See Also:
Fixed In Version: 3.23-9.fc10
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-09-29 10:28:01 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
test script exhibiting bug (509 bytes, application/x-perl)
2009-09-24 18:45 EDT, Jeff Fearn
no flags Details
fix that bug! (609 bytes, patch)
2009-09-24 18:54 EDT, Jeff Fearn
no flags Details | Diff


External Trackers
Tracker ID Priority Status Summary Last Updated
CPAN 49932 None None None Never

  None (edit)
Description Jeff Fearn 2009-09-24 18:45:31 EDT
Created attachment 362580 [details]
test script exhibiting bug

Description of problem:
HTML::Element::as_XML() has a bug where tags added to empty_element_map but which contain data are missing their close tag when generating XML.

Version-Release number of selected component (if applicable):
3.23-4

How reproducible:
Always

Steps to Reproduce:
1. Run attached script
  
Actual results:

Not mapped to empty element (correct)
         <a href="http://example.com/"></a>

Mapped to empty element, no extra content (correct)
        <a href="http://example.com/" />

Mapped to empty element, extra content (missing close tag)
        <a href="http://example.com/">Extra content



Expected results:

Not mapped to empty element (correct)
         <a href="http://example.com/"></a>

Mapped to empty element, no extra content (correct)
        <a href="http://example.com/" />

Mapped to empty element, extra content (correct)
        <a href="http://example.com/">Extra content</a>



Additional info:

I opened an upstream bug with a patch https://rt.cpan.org/Ticket/Display.html?id=49932 however it may take a while for a new version to come out.

Since HTML::Element is the base class for XML::Element this bug affects all XML systems where tags can be optionally empty and people wish to use the short circuit form for the empty tags.
Comment 1 Jeff Fearn 2009-09-24 18:54:44 EDT
Created attachment 362581 [details]
fix that bug!
Comment 2 Tom "spot" Callaway 2009-09-28 10:45:54 EDT
Updates are building for this now, thanks for the patch.
Comment 3 Fedora Update System 2009-09-28 12:04:53 EDT
perl-HTML-Tree-3.23-9.el4 has been submitted as an update for Fedora EPEL 4.
http://admin.fedoraproject.org/updates/perl-HTML-Tree-3.23-9.el4
Comment 4 Fedora Update System 2009-09-28 12:04:58 EDT
perl-HTML-Tree-3.23-9.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/perl-HTML-Tree-3.23-9.el5
Comment 5 Fedora Update System 2009-09-28 12:05:44 EDT
perl-HTML-Tree-3.23-9.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/perl-HTML-Tree-3.23-9.fc10
Comment 6 Fedora Update System 2009-09-28 12:05:49 EDT
perl-HTML-Tree-3.23-9.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/perl-HTML-Tree-3.23-9.fc11
Comment 7 Fedora Update System 2009-09-29 10:27:56 EDT
perl-HTML-Tree-3.23-9.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 8 Fedora Update System 2009-09-29 10:37:37 EDT
perl-HTML-Tree-3.23-9.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 9 Fedora Update System 2009-10-16 15:31:51 EDT
perl-HTML-Tree-3.23-9.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 10 Fedora Update System 2009-10-16 15:32:53 EDT
perl-HTML-Tree-3.23-9.el4 has been pushed to the Fedora EPEL 4 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 11 GEORGE GIANNAKIS 2009-10-27 12:22:42 EDT
Eftimios TSIGROS (BANNER)!!!!!!!!!

Note You need to log in before you can comment on or make changes to this bug.