[ruby-core:76909] [Ruby trunk Bug#12609] rexml attribute class is using &quote instead of &quot when replacing " for the XML character entity "

From: usa@...
Date: 2016-08-16 04:39:36 UTC
List: ruby-core #76909
Issue #12609 has been updated by Usaku NAKAMURA.

Backport changed from 2.1: REQUIRED, 2.2: REQUIRED, 2.3: REQUIRED to 2.1: REQUIRED, 2.2: DONE, 2.3: REQUIRED

ruby_2_2 r55922 merged revision(s) 55726,55727.

----------------------------------------
Bug #12609: rexml attribute class is using &quote instead of &quot when replacing " for the XML character entity "
https://bugs.ruby-lang.org/issues/12609#change-60139

* Author: Joseph Marrero
* Status: Closed
* Priority: Normal
* Assignee: Kouhei Sutou
* ruby -v: 
* Backport: 2.1: REQUIRED, 2.2: DONE, 2.3: REQUIRED
----------------------------------------
lib/rexml/attribute.rb to_string method is using &quote instead of &quot when replacing double quotes.


https://www.w3.org/standards/xml/core

States:
" In XML, there are only five built-in character entities: &lt;, &gt;, &amp;, &quot; and &apos; for <, >, &, " and ' respectively. "

Notice it is &quot and not &quote

Also here is an exaple (http://www.w3schools.com/xml/xml_attributes.asp) on how to use quotes, notice ", ' and &quot are mentioned not &quote this follows the above spec.

The included patch fixes the simple issue.

---Files--------------------------------
quot-change.patch (557 Bytes)


-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>

In This Thread

Prev Next