Selaa lähdekoodia

FOP-2336 OOM for tiff output

git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@1590653 13f79535-47bb-0310-9956-ffa450edef68
tags/fop-2_0
Simon Steiner 10 vuotta sitten
vanhempi
commit
040e4a7bbe

+ 3
- 2
src/java/org/apache/fop/render/bitmap/AbstractBitmapDocumentHandler.java Näytä tiedosto

} }


//Set up bitmap to paint on //Set up bitmap to paint on
this.currentImage = createBufferedImage(bitmapWidth, bitmapHeight);
if (currentImage == null || currentImage.getWidth() != bitmapWidth || currentImage.getHeight() != bitmapHeight) {
currentImage = createBufferedImage(bitmapWidth, bitmapHeight);
}
Graphics2D graphics2D = this.currentImage.createGraphics(); Graphics2D graphics2D = this.currentImage.createGraphics();


// draw page background // draw page background
this.multiImageWriter.writeImage(this.currentImage, this.multiImageWriter.writeImage(this.currentImage,
getSettings().getWriterParams()); getSettings().getWriterParams());
} }
this.currentImage = null;
} catch (IOException ioe) { } catch (IOException ioe) {
throw new IFException("I/O error while encoding BufferedImage", ioe); throw new IFException("I/O error while encoding BufferedImage", ioe);
} }

Loading…
Peruuta
Tallenna