IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 8, 2008, 8:17:12 AM (18 years ago)
Author:
Paul Price
Message:

Fixing following changes to psThread.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppMerge/src/ppMergeCamera.c

    r18756 r18967  
    3131            if (! pmFPASelectChip(fpa, chipNum, false)) {
    3232                psError(PS_ERR_IO, false, "Chip number %d doesn't exist in camera.\n", chipNum);
    33                 psFree (chips);
     33                psFree (chips);
    3434                return false;
    3535            }
     
    4343    psArray *cells = psStringSplitArray (cellLine, ",", false);
    4444    if (cells->n > 0) {
    45         for (int i = 0; i < fpa->chips->n; i++) {
    46             pmChip *chip = fpa->chips->data[i];
    47             pmChipSelectCell (chip, -1, true); // deselect all cells
    48             for (int j = 0; j < cells->n; j++) {
    49                 int cellNum = atoi(cells->data[j]);
    50                 if (! pmChipSelectCell(chip, cellNum, false)) {
    51                     psError(PS_ERR_IO, false, "Cell number %d doesn't exist in camera.\n", cellNum);
    52                     psFree (cells);
    53                     return false;
    54                 }
    55             }
    56         }
     45        for (int i = 0; i < fpa->chips->n; i++) {
     46            pmChip *chip = fpa->chips->data[i];
     47            pmChipSelectCell (chip, -1, true); // deselect all cells
     48            for (int j = 0; j < cells->n; j++) {
     49                int cellNum = atoi(cells->data[j]);
     50                if (! pmChipSelectCell(chip, cellNum, false)) {
     51                    psError(PS_ERR_IO, false, "Cell number %d doesn't exist in camera.\n", cellNum);
     52                    psFree (cells);
     53                    return false;
     54                }
     55            }
     56        }
    5757    }
    5858    psFree (cells);
     
    259259                    cell->file_exists = false;
    260260                    culled++;
    261                     if (cell->concepts) {
    262                         psFree(cell->concepts);
    263                         cell->concepts = NULL;
    264                     }
     261                    if (cell->concepts) {
     262                        psFree(cell->concepts);
     263                        cell->concepts = NULL;
     264                    }
    265265                }
    266266            }
     
    268268                chip->data_exists = false;
    269269                chip->file_exists = false;
    270                 if (chip->concepts) {
    271                     psFree(chip->concepts);
    272                     chip->concepts = NULL;
    273                 }
     270                if (chip->concepts) {
     271                    psFree(chip->concepts);
     272                    chip->concepts = NULL;
     273                }
    274274            }
    275275        }
     
    298298    }
    299299
    300     // Output image
    301     pmFPA *fpa = pmFPAConstruct(config->camera, config->cameraName); // FPA to contain the output
    302     if (!fpa) {
    303         psError(PS_ERR_UNEXPECTED_NULL, false, "Unable to construct an FPA from camera configuration.");
    304         psFree(phuView);
    305         return false;
    306     }
    307 
    308300    psString outName = ppMergeOutputFile(config); // Name of output file
    309301
Note: See TracChangeset for help on using the changeset viewer.