Index: trunk/psphot/src/psphotModelTest.c
===================================================================
--- trunk/psphot/src/psphotModelTest.c	(revision 6311)
+++ trunk/psphot/src/psphotModelTest.c	(revision 6379)
@@ -1,4 +1,5 @@
 # include "psphot.h"
 # include "psEllipse.h"
+static char DEFAULT_MODE[] = "EXT";
 
 bool psphotModelTest (pmReadout *readout, psMetadata *arguments, psMetadata *recipe) {
@@ -17,7 +18,7 @@
 
     // what fitting mode to use?
-    char *psfModeWord = psMetadataLookupPtr (&status, arguments, "TEST_FIT_MODE");
+    char *psfModeWord = psMetadataLookupStr (&status, arguments, "TEST_FIT_MODE");
     if (!status) {
-	psfModeWord = psStringCopy ("EXT");
+	psfModeWord = DEFAULT_MODE;
     }
     bool psfMode = !strcasecmp (psfModeWord, "PSF");
@@ -25,5 +26,5 @@
     // in psfMode, psf sets the model type
     if (psfMode) {
-	char *psfFile = psMetadataLookupPtr (&status, arguments, "PSF_INPUT_FILE");
+	char *psfFile = psMetadataLookupStr (&status, arguments, "PSF_INPUT_FILE");
 	if (!status) psAbort ("psphotModelTest", "PSF_INPUT_FILE not supplied");
 	psMetadata *psfData = psMetadataConfigParse (NULL, &Nfail, psfFile, FALSE);
@@ -32,5 +33,5 @@
     } else {
 	// find the model: supplied by user or first in the PSF_MODEL list
-	char *modelName  = psMetadataLookupPtr (&status, arguments, "TEST_FIT_MODEL");
+	char *modelName  = psMetadataLookupStr (&status, arguments, "TEST_FIT_MODEL");
 	if (modelName == NULL) {
 	    // get the list pointers for the PSF_MODEL entries
@@ -153,5 +154,5 @@
     psImageKeepCircle (source->mask, xObj, yObj, RADIUS, "OR", PSPHOT_MASK_MARKED);
 
-    char *fitset = psMetadataLookupPtr (&status, arguments, "TEST_FIT_SET");
+    char *fitset = psMetadataLookupStr (&status, arguments, "TEST_FIT_SET");
     if (status) {
 	status = psphotFitSet (source, model, fitset, psfMode);
