NPE while reading the session scope when no session has been created
--------------------------------------------------------------------

                 Key: TREQ-10
                 URL: https://issues.apache.org/jira/browse/TREQ-10
             Project: Tiles Request
          Issue Type: Bug
    Affects Versions: 1.0.0
            Reporter: Nicolas Le Bas


If no HttpSession has been created, the following code leads to an exception:

Map<String, Object> scopes = new HashMap<String, Object>();
Map<String, Object> data = request.getContext("session");
scopes.putAll(data);

java.lang.NullPointerException
        
org.apache.tiles.request.util.RequestUtil.enumerationSize(RequestUtil.java:64)
        
org.apache.tiles.request.collection.ReadOnlyEnumerationMap.size(ReadOnlyEnumerationMap.java:128)
        java.util.HashMap.putAll(HashMap.java:498)


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to