Avoid NullPointerException if an image cannot be read

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1674952 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Dominik Stadler 2015-04-20 18:10:43 +00:00
parent 208955bc8c
commit 1201332d48
2 changed files with 4 additions and 0 deletions

View File

@ -99,6 +99,10 @@ public class XSLFImageRenderer {
} catch (Exception e) {
return false;
}
if(img == null) {
return false;
}
int iw = img.getWidth();
int ih = img.getHeight();