Hello,

within the init() of a filter, I'm storing a reference to the servletContext:

filterConfig.getServletContext().setAttribute("servletContext", filterConfig.getServletContext());

But when I'm trying to access this attribute in the doFilter-method, I get a NullPointerException:

ServletContext servletContext = (ServletContext) request.getAttribute("servletContext");

Why doesn't this work?

Regards
Marten

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to