IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 5, 2018, 4:17:43 PM (8 years ago)
Author:
watersc1
Message:

Be more aggressive at checking parameters for the PSREFCAT field, as dependent code isn't run when quality != 0 and the warping process is being aborted.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/pswarp/src/pswarpLoopBackground.c

    r40345 r40354  
    137137                    if (astrom != input) {
    138138                      pmReadout *astromRO = pmFPAviewThisReadout(view, astrom->fpa); // Readout for astrometry
    139                       if (!refcat) {
    140                         refcat = psMetadataLookupStr(NULL, astromRO->parent->parent->hdu->header, "PSREFCAT");
    141 
    142                         psMetadataAddStr(output->fpa->analysis, PS_LIST_TAIL, "REFERENCE_CATALOG", PS_META_REPLACE, "Reference catalog used for calibration.", refcat);
     139                      if ((!refcat)&&(astromRO)) {
     140                        if ((astromRO->parent->parent->hdu->header)&&(output->fpa->analysis)) {
     141                          psMetadataItem *refItem = psMetadataLookup(astromRO->parent->parent->hdu->header, "PSREFCAT");
     142                          if (refItem) {
     143                            refcat = psMetadataLookupStr(NULL, astromRO->parent->parent->hdu->header, "PSREFCAT");
     144                            psMetadataAddStr(output->fpa->analysis, PS_LIST_TAIL, "REFERENCE_CATALOG", PS_META_REPLACE,
     145                                             "Reference catalog used for calibration.", refcat);
     146                          }
     147                        }
    143148                      }
    144149                    }
Note: See TracChangeset for help on using the changeset viewer.