DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14770>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14770

PDF Renderer does not work with .bmp images.

[EMAIL PROTECTED] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID



------- Additional Comments From [EMAIL PROTECTED]  2002-11-23 21:03 -------
Your servlet works very inaccurately with those buffers:
byte[] chunk = new byte[4096];
while (fis.read(chunk) > 0)
{
    dos.write(chunk);
}
Think what a garbage you are outputting in a very last iteration. 
When you are copying buffers always make sure you are writing the same amount of
bytes you are reading. Use the following pattern:

int bytesRead;
byte[] chunk = new byte[4096];
while ((bytesRead = fis.read(chunk)) > 0)
{
    dos.write(chunk, 0, bytesRead);                    
}

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

Reply via email to