IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 1, 2006, 2:55:23 PM (20 years ago)
Author:
Paul Price
Message:

Addition of a vast quantity of assertions in public functions. Adopted a policy of using assert() within file-static functions (since they are only called internally, any errors there are problems with the program) and using the PS_ASSERT_WHATEVER() macros within public functions. Cleaned a few things up in the process.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/camera/pmHDUUtils.c

    r7168 r7278  
    88                   )
    99{
     10    PS_ASSERT_PTR_NON_NULL(fpa, NULL);
    1011    return fpa->hdu;
    1112}
     
    1415                    )
    1516{
     17    PS_ASSERT_PTR_NON_NULL(chip, NULL);
     18
    1619    pmHDU *hdu = chip->hdu;             // The HDU information
    1720    if (!hdu) {
     
    2528                    )
    2629{
     30    PS_ASSERT_PTR_NON_NULL(cell, NULL);
     31
    2732    pmHDU *hdu = cell->hdu;             // The HDU information
    2833    if (!hdu) {
     
    3338}
    3439
    35 pmHDU *pmHDUFromReadout (pmReadout *readout)
     40pmHDU *pmHDUFromReadout(pmReadout *readout)
    3641{
     42    PS_ASSERT_PTR_NON_NULL(readout, NULL);
    3743
    3844    pmCell *cell = readout->parent; // cell containing this readout;
    39     pmHDU *hdu = pmHDUFromCell (cell);
     45    pmHDU *hdu = pmHDUFromCell(cell);
    4046    return hdu;
    4147}
     
    6470               )
    6571{
     72    PS_ASSERT_PTR_NON_NULL(hdu,);
     73
    6674    if (hdu->phu) {
    6775        psTrace(__func__, level, "HDU: %s (PHU)\n", hdu->extname);
Note: See TracChangeset for help on using the changeset viewer.