shiro-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dan Diephouse (JIRA)" <j...@apache.org>
Subject [jira] Created: (SHIRO-234) ClassCastException in checkRoles
Date Thu, 13 Jan 2011 00:47:47 GMT
ClassCastException in checkRoles
--------------------------------

                 Key: SHIRO-234
                 URL: https://issues.apache.org/jira/browse/SHIRO-234
             Project: Shiro
          Issue Type: Bug
    Affects Versions: 1.1.0
            Reporter: Dan Diephouse


I get the following:

java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to [Ljava.lang.String;
	at org.apache.shiro.authz.ModularRealmAuthorizer.checkRoles(ModularRealmAuthorizer.java:426)

In checkRoles, the collection is incorrectly cast to a String[]. The line needs to do toArray(new
String[roles.size]) and not toArray().


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


Mime
View raw message