IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 6722


Ignore:
Timestamp:
Mar 28, 2006, 3:39:29 PM (20 years ago)
Author:
Paul Price
Message:

Adding some error checking.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/rel10_ifa/psModules/src/astrom/pmHDU.c

    r6663 r6722  
    7575        psTrace(__func__, 5, "Reading the header...\n");
    7676        hdu->header = psFitsReadHeader(NULL, fits);
     77        if (! hdu->header) {
     78            psError(PS_ERR_IO, false, "Unable to read header for extension %s\n", hdu->extname);
     79            return false;
     80        }
    7781    }
    7882
     
    8791        psTrace(__func__, 5, "Reading the pixels...\n");
    8892        hdu->images = psFitsReadImageCube(fits, psRegionSet(0,0,0,0));
     93        if (! hdu->images) {
     94            psError(PS_ERR_IO, false, "Unable to read pixels for extension %s\n", hdu->extname);
     95            return false;
     96        }
    8997        return true;
    9098        #ifdef FITS_TABLES
Note: See TracChangeset for help on using the changeset viewer.