Skip to content
This repository has been archived by the owner on Mar 15, 2021. It is now read-only.

Commit

Permalink
Protect against exceptions from invalid dimensioned skins
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeprimm committed Apr 4, 2012
1 parent 3ba39f7 commit 69c2103
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/java/org/dynmap/PlayerFaces.java
Expand Up @@ -65,6 +65,10 @@ public void run() {
if(img == null) { /* No image to process? Quit */
return;
}
if((img.getWidth() < 64) || (img.getHeight() < 32)) {
img.flush();
return;
}
int[] faceaccessory = new int[64]; /* 8x8 of face accessory */
/* Get buffered image for face at 8x8 */
DynmapBufferedImage face8x8 = DynmapBufferedImage.allocateBufferedImage(8, 8);
Expand Down

0 comments on commit 69c2103

Please sign in to comment.