-
Tomcat5.5 error report
hello friends,
I am using a following code. it is working fine in development. but it didnt work. it gives the error report. what will be the problem.... its very urgent........ please help me.....
code: session = httpRequest.getSession();
ValidUser user = ( ValidUser )session.getAttribute(sess_id);
it is working fine in tomcat5.0..... but 5.5 raises this exception.....
org.apache.catalina.session.StandardSessionFacade@ 1c7980c
: null
java.lang.NullPointerException
at java.util.Hashtable.get(Hashtable.java:334)
at
org.apache.catalina.session.StandardSession.getAtt ribute(StandardSession.java:1024)
at
org.apache.catalina.session.StandardSessionFacade. getAttribute(StandardSessionFacade.java:110)
at
-
The error message lists several class names and gives source line numbers in those classes where the error occured. Are any of the listed classes yours? If so please locate the listed line numbers and copy and paste those lines of code here.
Add a println() statement before the topmost/last executed line number in the list that displays the contents of ALL the objects referenced in the line with the error. Be sure to include any objects that my be returned by methods. That should show you which object is null. Then you need to back track to see why that object is null.