IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 23, 2008, 3:54:24 PM (18 years ago)
Author:
Paul Price
Message:

Only add to stats if it's not NULL.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppSub/src/ppSubReadout.c

    r17790 r17793  
    246246        pmFPAfileActivate(config->files, false, "PSPHOT.INPUT");
    247247
    248         pmChip *photChip = pmFPAviewThisChip(view, photFile->fpa); // Chip with the sources
    249         psArray *sources = psMetadataLookupPtr(NULL, photChip->analysis, "PSPHOT.SOURCES"); // Sources
    250         psMetadataAddS32(stats, PS_LIST_TAIL, "NUM_SOURCES", 0, "Number of sources detected", sources->n);
     248        if (stats) {
     249            pmChip *photChip = pmFPAviewThisChip(view, photFile->fpa); // Chip with the sources
     250            psArray *sources = psMetadataLookupPtr(NULL, photChip->analysis, "PSPHOT.SOURCES"); // Sources
     251            psMetadataAddS32(stats, PS_LIST_TAIL, "NUM_SOURCES", 0, "Number of sources detected", sources->n);
     252        }
    251253    }
    252254
Note: See TracChangeset for help on using the changeset viewer.