IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 13685


Ignore:
Timestamp:
Jun 6, 2007, 2:04:09 PM (19 years ago)
Author:
Paul Price
Message:

Making unneccessary error go away.

File:
1 edited

Legend:

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

    r13659 r13685  
    7272        }
    7373    }
     74    psFree (skyConfig);
    7475
    7576    // Chip selection: turn on only the chips specified
    76     char *chipLine = psMetadataLookupStr(NULL, config->arguments, "CHIP_SELECTIONS");
    77     psArray *chips = psStringSplitArray (chipLine, ",", false);
    78     if (chips->n > 0) {
    79         pmFPASelectChip (input->fpa, -1, true); // deselect all chips
    80         for (int i = 0; i < chips->n; i++) {
    81             int chipNum = atoi(chips->data[i]);
    82             if (! pmFPASelectChip(input->fpa, chipNum, false)) {
    83                 psError(PSWARP_ERR_CONFIG, true, "Chip number %d doesn't exist in camera.\n", chipNum);
    84                 return false;
     77    bool mdok;                          // Status of MD lookup
     78    char *chipLine = psMetadataLookupStr(&mdok, config->arguments, "CHIP_SELECTIONS");
     79    if (mdok) {
     80        psArray *chips = psStringSplitArray (chipLine, ",", false);
     81        if (chips->n > 0) {
     82            pmFPASelectChip (input->fpa, -1, true); // deselect all chips
     83            for (int i = 0; i < chips->n; i++) {
     84                int chipNum = atoi(chips->data[i]);
     85                if (! pmFPASelectChip(input->fpa, chipNum, false)) {
     86                    psError(PSWARP_ERR_CONFIG, true, "Chip number %d doesn't exist in camera.\n", chipNum);
     87                    return false;
     88                }
    8589            }
    8690        }
     91        psFree (chips);
    8792    }
    88     psFree (chips);
    89     psFree (skyConfig);
    9093
    9194    psTrace("pswarp", 1, "Done with pswarpParseCamera...\n");
Note: See TracChangeset for help on using the changeset viewer.