mirror of https://github.com/apache/poi.git
try to fix NPE in tests
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1863516 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
cf1eb05304
commit
21ed5240e7
|
@ -239,6 +239,9 @@ public class BitmapImageRenderer implements ImageRenderer {
|
|||
|
||||
@Override
|
||||
public BufferedImage getImage(Dimension2D dim) {
|
||||
if (img == null) {
|
||||
return img;
|
||||
}
|
||||
double w_old = img.getWidth();
|
||||
double h_old = img.getHeight();
|
||||
BufferedImage scaled = new BufferedImage((int)w_old, (int)h_old, BufferedImage.TYPE_INT_ARGB);
|
||||
|
|
Loading…
Reference in New Issue