Hi,

i am having a big trouble using the oreilly upload classes.

I am using it like this:

MultipartRequest obj_multi = new MultipartRequest(request, myFolder,
1024*8192); // 8MB maximum storage

When it begins to upload the file, the following error is displayed...

"Corrupt form data: premature ending"

i  have no idea why is happennig that...  i tested it using tomcat 3.1
under solaris 2.6 and it works fine, i tested it using tomcat 3.1 under
windows nt and it works...
but in the production server it fails :(, the production server uses
Iplanet 4.1 under solaris...

i  read the iplanet documentation and it says:
-----------------------------------------------------------
----------Begin iplanet documenration---------------------
-----------------------------------------------------------
Request.getInputStream and getReader

   There are two ways for a servlet to read the raw data posted by a
client:

       by obtaining the InputStream through the request.InputStream
method, an older method.

       by obtaining a BufferedRead through the request.getReader method,
a method in use since 2.0.


   Clarification

   A servlet hangs if it attempts to use an InputStream to read more
data than is physically available. (To find how much data is available, use
   request.getContentLength.) However, if the servlet reads data using a
BufferedReader returned from a call to getReader, the allowed content
length is
   automatically taken into account.

   You can also set the inputStreamLengthCheck parameter to true in the
contexts.properties file to prevent this problem.
-----------------------------------------------------------
----------End iplanet documenration---------------------
-----------------------------------------------------------

I look into the MultipartRequest code and i saw that it uses the
InputStream instead of the BufferedReader, i try to change the code but
i always get the following error:
"Corrupt form data: no leading boundary"

Any ideas?

Thanks in advance..

Javier Galindo
[EMAIL PROTECTED]

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to