You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by "Nikola Sprljan (JIRA)" <xe...@xml.apache.org> on 2015/09/29 15:35:04 UTC

[jira] [Created] (XERCESJ-1665) DTDGrammar.QNameHashtable.get(String key) compares by reference

Nikola Sprljan created XERCESJ-1665:
---------------------------------------

             Summary: DTDGrammar.QNameHashtable.get(String key) compares by reference
                 Key: XERCESJ-1665
                 URL: https://issues.apache.org/jira/browse/XERCESJ-1665
             Project: Xerces2-J
          Issue Type: Bug
          Components: DTD
            Reporter: Nikola Sprljan
            Priority: Minor


When key is matched with bucket the reference comparison is done:
{noformat}
if ((String)bucket[j] == key) {
{noformat}
This will work if a string literal is provided as a key, but not for any String object. As a consequence dtdGrammar.getElementDeclIndex(String s) does not work for String objects. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: j-dev-help@xerces.apache.org