0 Replies Latest reply on Nov 3, 2005 5:46 AM by Caspar Nielsen

    NullpointerException with large content

    Caspar Nielsen Newbie

      I have made a JSP from where it's possible to upload files to the server. Once the file is uploaded it is base64 encoded and the resulting string is inserted in a textarea in the JSP. The page is then submited to the server.

      My problem is that when I try to get the content of the field using request.getParameter("base64file") I get the following error:

      java.lang.NullPointerException
       org.apache.catalina.connector.Request.parseParameters(Request.java:2340)
       org.apache.catalina.connector.Request.getParameterNames(Request.java:1038)
       org.apache.catalina.connector.RequestFacade.getParameterNames(RequestFacade.java:359)
       org.apache.jsp.SendMail_jsp._jspService(org.apache.jsp.SendMail_jsp:122)
       org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
       javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
       org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
       org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
       org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
       javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
       org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
      


      I only get the problem if I upload a large file (2mb+). I think that it has something to do with size of the request, as it now contains the base64 encoded file. Does anyone know what to do?