Index: trunk/archive/scripts/src/phase2/pmFPAConstruct.c
===================================================================
--- trunk/archive/scripts/src/phase2/pmFPAConstruct.c	(revision 5564)
+++ trunk/archive/scripts/src/phase2/pmFPAConstruct.c	(revision 5583)
@@ -141,6 +141,4 @@
 		    }
 		    // The cell
-		    psArray *images = NULL;
-		    psMetadata *header = NULL;
 		    psMetadata *cellData = getCellData(camera, cellType);
 		    pmCell *cell = pmCellAlloc(chip, cellData, extName); // The cell
@@ -242,10 +240,10 @@
 		const char *cellType = contentItem->data.V; // The type of cell
 		psTrace(__func__, 5, "Cell type is %s\n", cellType);
-		psArray *images = NULL;
-		psMetadata *header = NULL;
 		psMetadata *cellData = getCellData(camera, cellType);
 		pmCell *cell = pmCellAlloc(chip, cellData, extName); // The cell
 //		psFree(cellData);
 		cell->hdu = p_pmHDUAlloc(extName); // Prepare cell to receive FITS data
+
+		psFree(cell);
 	    } // Iterating through contents
 	    psFree(contentsIter);
@@ -256,4 +254,6 @@
 	    return NULL;
 	}
+	psFree(chipName);
+	psFree(chip);
 
     } else {
