You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Kevin Zhou (JIRA)" <ji...@apache.org> on 2008/11/13 11:41:44 UTC

[jira] Created: (HARMONY-6017) [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException

[classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException
-----------------------------------------------------------------------

                 Key: HARMONY-6017
                 URL: https://issues.apache.org/jira/browse/HARMONY-6017
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
    Affects Versions: 5.0M7
            Reporter: Kevin Zhou
             Fix For: 5.0M8


Given a test case [1], HARMONY will throws ClassCastException while RI works well. This also occurs when cast Hashtable.elements() to Iterator and cast Hashtable.keySet().iterator() to Enumeration.

[1]
public void test_HashTable_keys() {
        Hashtable hashTable = new Hashtable();
        hashTable.put("key", "value");

        // cast Enumeration to Iterator
        Iterator iterator = (Iterator) hashTable.keys();
}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HARMONY-6017) [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException

Posted by "Kevin Zhou (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6017?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kevin Zhou updated HARMONY-6017:
--------------------------------

    Attachment: HARMONY-6017.diff

Would you please help to try this patch?

> [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-6017
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6017
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Kevin Zhou
>             Fix For: 5.0M8
>
>         Attachments: HARMONY-6017.diff
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> Given a test case [1], HARMONY will throws ClassCastException while RI works well. This also occurs when cast Hashtable.elements() to Iterator and cast Hashtable.keySet().iterator() to Enumeration.
> [1]
> public void test_HashTable_keys() {
>         Hashtable hashTable = new Hashtable();
>         hashTable.put("key", "value");
>         // cast Enumeration to Iterator
>         Iterator iterator = (Iterator) hashTable.keys();
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (HARMONY-6017) [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException

Posted by "Kevin Zhou (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6017?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kevin Zhou closed HARMONY-6017.
-------------------------------


> [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-6017
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6017
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Kevin Zhou
>            Assignee: Tim Ellison
>             Fix For: 5.0M9
>
>         Attachments: HARMONY-6017.diff
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> Given a test case [1], HARMONY will throws ClassCastException while RI works well. This also occurs when cast Hashtable.elements() to Iterator and cast Hashtable.keySet().iterator() to Enumeration.
> [1]
> public void test_HashTable_keys() {
>         Hashtable hashTable = new Hashtable();
>         hashTable.put("key", "value");
>         // cast Enumeration to Iterator
>         Iterator iterator = (Iterator) hashTable.keys();
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (HARMONY-6017) [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException

Posted by "Tim Ellison (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6017?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tim Ellison reassigned HARMONY-6017:
------------------------------------

    Assignee: Tim Ellison

> [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-6017
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6017
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Kevin Zhou
>            Assignee: Tim Ellison
>             Fix For: 5.0M8
>
>         Attachments: HARMONY-6017.diff
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> Given a test case [1], HARMONY will throws ClassCastException while RI works well. This also occurs when cast Hashtable.elements() to Iterator and cast Hashtable.keySet().iterator() to Enumeration.
> [1]
> public void test_HashTable_keys() {
>         Hashtable hashTable = new Hashtable();
>         hashTable.put("key", "value");
>         // cast Enumeration to Iterator
>         Iterator iterator = (Iterator) hashTable.keys();
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (HARMONY-6017) [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException

Posted by "Tim Ellison (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6017?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tim Ellison resolved HARMONY-6017.
----------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: 5.0M8)
                   5.0M9

Thanks Kevin.

Patch applied to LUNI module at repo revision r718321.

Please check it was applied as you expected.


> [classlib] [luni] (Iterator) Hashtable.keys() throws ClassCastException
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-6017
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6017
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Kevin Zhou
>            Assignee: Tim Ellison
>             Fix For: 5.0M9
>
>         Attachments: HARMONY-6017.diff
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> Given a test case [1], HARMONY will throws ClassCastException while RI works well. This also occurs when cast Hashtable.elements() to Iterator and cast Hashtable.keySet().iterator() to Enumeration.
> [1]
> public void test_HashTable_keys() {
>         Hashtable hashTable = new Hashtable();
>         hashTable.put("key", "value");
>         // cast Enumeration to Iterator
>         Iterator iterator = (Iterator) hashTable.keys();
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.