Index: trunk/psastro/src/psastro.h
===================================================================
--- trunk/psastro/src/psastro.h	(revision 27638)
+++ trunk/psastro/src/psastro.h	(revision 27639)
@@ -82,5 +82,5 @@
 bool              psastroOneChip (pmFPA *fpa, pmChip *chip, psArray *refset, psArray *rawset, psMetadata *recipe, psMetadata *updates);
 bool              psastroOneChipGrid (pmFPA *fpa, pmChip *chip, psArray *refset, psArray *rawset, psMetadata *recipe, psMetadata *updates);
-bool              psastroOneChipFit (pmFPA *fpa, pmChip *chip, psArray *refset, psArray *rawset, psMetadata *recipe, psMetadata *updates);
+bool              psastroOneChipFit (pmFPA *fpa, pmChip *chip, pmReadout *readout, psArray *refset, psArray *rawset, psMetadata *recipe, psMetadata *updates);
 bool              psastroChooseRefstars (pmConfig *config, psArray *refs, const char *source);
 bool              psastroRefstarSubset (pmReadout *readout);
Index: trunk/psastro/src/psastroChipAstrom.c
===================================================================
--- trunk/psastro/src/psastroChipAstrom.c	(revision 27638)
+++ trunk/psastro/src/psastroChipAstrom.c	(revision 27639)
@@ -86,5 +86,5 @@
                 }
                 // XXX update the header with info to reflect the failure
-                if (!psastroOneChipFit (fpa, chip, refstars, rawstars, recipe, updates)) {
+                if (!psastroOneChipFit (fpa, chip, readout, refstars, rawstars, recipe, updates)) {
                     readout->data_exists = false;
                     psLogMsg ("psastro", 3, "failed to find a solution\n");
Index: trunk/psastro/src/psastroFixChips.c
===================================================================
--- trunk/psastro/src/psastroFixChips.c	(revision 27638)
+++ trunk/psastro/src/psastroFixChips.c	(revision 27639)
@@ -329,5 +329,5 @@
 
         // XXX update the header with info to reflect the failure
-        if (!psastroOneChipFit (input->fpa, obsChip, refstars, rawstars, recipe, updates)) {
+        if (!psastroOneChipFit (input->fpa, obsChip, readout, refstars, rawstars, recipe, updates)) {
             readout->data_exists = false;
             psLogMsg ("psastro", 3, "failed to find a solution\n");
Index: trunk/psastro/src/psastroFixChipsTest.c
===================================================================
--- trunk/psastro/src/psastroFixChipsTest.c	(revision 27638)
+++ trunk/psastro/src/psastroFixChipsTest.c	(revision 27639)
@@ -252,5 +252,5 @@
 
 	// XXX update the header with info to reflect the failure
-	if (!psastroOneChipFit (fpa, chip, refstars, rawstars, recipe, updates)) {
+	if (!psastroOneChipFit (fpa, chip, readout, refstars, rawstars, recipe, updates)) {
 	    readout->data_exists = false;
 	    psLogMsg ("psastro", 3, "failed to find a solution\n");
Index: trunk/psastro/src/psastroOneChipFit.c
===================================================================
--- trunk/psastro/src/psastroOneChipFit.c	(revision 27638)
+++ trunk/psastro/src/psastroOneChipFit.c	(revision 27639)
@@ -18,5 +18,5 @@
    psAbort ("Failed to find %s in recipe", NAME); }
 
-bool psastroOneChipFit (pmFPA *fpa, pmChip *chip, psArray *refstars, psArray *rawstars, psMetadata *recipe, psMetadata *updates) {
+bool psastroOneChipFit (pmFPA *fpa, pmChip *chip, pmReadout *readout, psArray *refstars, psArray *rawstars, psMetadata *recipe, psMetadata *updates) {
 
     bool status;
@@ -212,4 +212,7 @@
     }
 
+    // save the match table for zero points and other tests
+    psMetadataAdd (readout->analysis, PS_LIST_TAIL, "PSASTRO.MATCH", PS_DATA_ARRAY | PS_META_REPLACE, "astrometry matches", match);
+
     psFree (match);
     psFree (results);
