IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 8, 2013, 2:06:39 PM (13 years ago)
Author:
eugene
Message:

correctly raise an error if we fail to generate mask or variance

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppImage/src/ppImageDetrendReadout.c

    r35685 r35917  
    6161        psImageMaskType satMask = options->doMaskSat ? options->satMask : 0;
    6262        psImageMaskType lowMask = options->doMaskLow ? options->lowMask : 0;
    63         pmReadoutGenerateMask(input, satMask, lowMask);
     63        if (!pmReadoutGenerateMask(input, satMask, lowMask)) {
     64          psError(PS_ERR_UNKNOWN, false, "Unable to generate a mask.");
     65          psFree(detview);
     66          return false;
     67        }
    6468    }
    6569    // apply the externally supplied mask to the input->mask pixels
     
    208212        }
    209213
    210         pmReadoutGenerateVariance(input, noiseImage, true);
     214        if (!pmReadoutGenerateVariance(input, noiseImage, true)) {
     215            psError(PS_ERR_UNKNOWN, false, "Unable to generate a variance image.");
     216            psFree(detview);
     217            return false;
     218        }
    211219        psFree (noiseImage);
    212220    }
Note: See TracChangeset for help on using the changeset viewer.