Changeset 13493
- Timestamp:
- May 23, 2007, 4:03:22 PM (19 years ago)
- Location:
- trunk/ppStack/src
- Files:
-
- 2 edited
-
ppStackCamera.c (modified) (6 diffs)
-
ppStackReadout.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppStack/src/ppStackCamera.c
r13489 r13493 24 24 } 25 25 psArray *images = psStringSplitArray(imageList, "\n", false); // The image filenames 26 psFree(imageList); 26 27 27 28 psString maskList = psSlurpFilename(maskName); // Contents of mask list … … 31 32 } 32 33 psArray *masks = psStringSplitArray(maskList, "\n", false); // The mask filenames 34 psFree(maskList); 33 35 if (images->n != masks->n) { 34 36 psError(PS_ERR_BAD_PARAMETER_VALUE, true, … … 57 59 58 60 psArray *imageFiles = psArrayAlloc(1); // Array of filenames for this FPA 59 imageFiles->data[0] = image;61 imageFiles->data[0] = psMemIncrRefCounter(image); 60 62 psMetadataAddArray(config->arguments, PS_LIST_TAIL, "IMAGE.FILENAMES", PS_META_REPLACE, 61 63 "Filenames of image files", imageFiles); … … 63 65 64 66 bool found = false; // Found the file? 65 pmFPAfile *imageFile = pmFPAfileDefineFromArgs(&found, config, "PPSTACK.INPUT", 66 "IMAGE.FILENAMES", true); 67 pmFPAfile *imageFile = pmFPAfileDefineFromArgs(&found, config, "PPSTACK.INPUT", "IMAGE.FILENAMES"); 67 68 if (!imageFile || !found) { 68 69 psError(PS_ERR_UNKNOWN, false, "Unable to define file from image %d (%s)", i, image); … … 79 80 80 81 psArray *maskFiles = psArrayAlloc(1); // Array of filenames for this FPA 81 maskFiles->data[0] = mask;82 maskFiles->data[0] = psMemIncrRefCounter(mask); 82 83 psMetadataAddArray(config->arguments, PS_LIST_TAIL, "MASK.FILENAMES", PS_META_REPLACE, 83 84 "Filenames of mask files", maskFiles); 85 psFree(maskFiles); 86 84 87 found = false; 85 88 pmFPAfile *maskFile = pmFPAfileBindFromArgs(&found, imageFile, config, "PPSTACK.INPUT.MASK", 86 "MASK.FILENAMES" , true);89 "MASK.FILENAMES"); 87 90 if (!maskFile || !found) { 88 91 psError(PS_ERR_UNKNOWN, false, "Unable to define file from mask %d (%s)", i, mask); … … 102 105 103 106 psMetadataAddS32(config->arguments, PS_LIST_TAIL, "INPUTS.NUM", 0, "Number of input files", images->n); 107 108 psFree(images); 109 psFree(masks); 104 110 105 111 // Output image -
trunk/ppStack/src/ppStackReadout.c
r13489 r13493 71 71 pmStackData *data = pmStackDataAlloc(ro, SEEING, WEIGHT); // Data to stack 72 72 psArrayAdd(stack, ARRAY_BUFFER, data); 73 psFree(data); // Drop reference 73 74 } 74 75 psFree(inputIter); … … 101 102 psFree(name); 102 103 psFitsWriteImage(fits, NULL, inspected, 0, NULL); 104 psFree(inspected); 103 105 psFitsClose(fits); 104 106 } … … 124 126 psFree(name); 125 127 psFitsWriteImage(fits, NULL, rejected, 0, NULL); 128 psFree(rejected); 126 129 psFitsClose(fits); 127 130 }
Note:
See TracChangeset
for help on using the changeset viewer.
