logo       

[enhydra] NPE in Enhydra.getApplication(): msg#00019

java.enhydra.general

Subject: [enhydra] NPE in Enhydra.getApplication()

Hi,

trying to get first Enhydra7 application deployed and getting all sorts of weird errors, for example:

Exception in thread "Thread-74" java.lang.NullPointerException
at com.lutris.appserver.server.Enhydra.getApplication(Enhydra.java:309)
at com.lutris.appserver.server.Enhydra.getLogChannel(Enhydra.java:357)
at com.lutris.appserver.server.sessionEnhydra.StandardSessionIdleTimer.run(StandardSessionIdleTimer.java:88)

Seems like the "applications" in the following function can be null:

public static Application getApplication () {
return (Application)applications.get(Thread.currentThread());
}

so obviously it should be rewritten as follows:

return (applications != null) ? (Application)applications.get(Thread.currentThread()) : null;

Petr


--
You receive this message as a subscriber of the enhydra@xxxxxxxxxxxxx mailing
list.
To unsubscribe: mailto:enhydra-unsubscribe@xxxxxxxxxxxxx
For general help: mailto:sympa@xxxxxxxxxxxxx?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise