6 Replies Latest reply on Jun 21, 2008 10:22 PM by juliobrazil

    Coldfusion 8 bug with GetPageContext().forward()


      I have a form that uses enctype="multipart/form-data" in a production server with Coldfusion MX 7 that's working fine. But when I try to move the application to the Coldfusion 8 it crashes!

      This error only happens when using GetPageContext().forward() after submiting the form. We need to use forward method after the submitting (instead of using the <cflocation>) because we want to keep the status of the page.

      The exception we get is the following one:

      Corrupt form data: premature ending

      The error occurred in D:\Inetpub\wwwroot\LRNSystemMVC\test.cfm: line 3

      1 : <cfif isDefined('form.submit')>
      2 : <cfscript>
      3 : GetPageContext().forward('index.cfm');
      4 : </cfscript>
      5 : </cfif>

      This is the stacktrace of the error:

      java.io.IOException: Corrupt form data: premature ending
      at com.oreilly.servlet.multipart.MultipartParser.<init>(MultipartParser.java:169)
      at com.oreilly.servlet.multipart.MultipartParser.<init>(MultipartParser.java:93)
      at coldfusion.filter.FormScope.fillMultipart(FormScope.java:136)
      at coldfusion.filter.FusionContext.SymTab_initForRequest(FusionContext.java:428)

      You can reproduce the error with the attached code.

      Thanks in advance,