Skip to content

Commit

Permalink
Add another sanity check: no 0 width images.
Browse files Browse the repository at this point in the history
  • Loading branch information
netterfield committed May 22, 2016
1 parent de686ad commit c10bd4a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/datasources/bis/bis.c
Expand Up @@ -169,7 +169,11 @@ int BISreadimage(BISfile *bis, int frame, int i_img, BISimage *I) {
I->h = image_dim[1];
I->x = image_dim[2];
I->y = image_dim[3];


if ((I->w < 1) || (I->h < 1)) {
I->w = I->h = I->x = I->y = 0;
return 0;
}

// read the image
img_size = I->w * I->h;
Expand Down

0 comments on commit c10bd4a

Please sign in to comment.