Changeset 5960


Ignore:
Timestamp:
02/25/10 17:28:48 (10 years ago)
Author:
curtis
Message:

Better error message if IFD indices don't line up.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/components/bio-formats/src/loci/formats/in/OMETiffReader.java

    r5712 r5960  
    171171      r.setId(info[series][no].id); 
    172172    } 
    173     IFD ifd = r.getIFDs().get(i); 
     173    IFDList ifdList = r.getIFDs(); 
     174    if (i <= ifdList.size()) { 
     175      throw new FormatException( 
     176        "Error untangling IFDs; the OME-TIFF file may be malformed."); 
     177    } 
     178    IFD ifd = ifdList.get(i); 
    174179    RandomAccessInputStream s = 
    175180      new RandomAccessInputStream(info[series][no].id); 
Note: See TracChangeset for help on using the changeset viewer.