Index: branches/eam_branches/ipp-20130419/pswarp/doc/notes.20130406.txt
===================================================================
--- branches/eam_branches/ipp-20130419/pswarp/doc/notes.20130406.txt	(revision 35436)
+++ branches/eam_branches/ipp-20130419/pswarp/doc/notes.20130406.txt	(revision 35449)
@@ -1,4 +1,4 @@
 
-examinging pswarp to handle inverse transformations or more general transformations:
+examining pswarp to handle inverse transformations or more general transformations:
 
 pswarp:
Index: branches/eam_branches/ipp-20130419/pswarp/src/pswarp.h
===================================================================
--- branches/eam_branches/ipp-20130419/pswarp/src/pswarp.h	(revision 35436)
+++ branches/eam_branches/ipp-20130419/pswarp/src/pswarp.h	(revision 35449)
@@ -94,4 +94,5 @@
 bool pswarpDefineBackground (pmConfig *config);
 bool pswarpLoop (pmConfig *config, psMetadata *stats);
+bool pswarpLoopSkycell (pmConfig *config, psMetadata *stats);
 bool pswarpLoopBackground (pmConfig *config, psMetadata *stats);
 psExit pswarpExitCode(psExit exitValue);
Index: branches/eam_branches/ipp-20130419/pswarp/src/pswarpLoadAstrometry.c
===================================================================
--- branches/eam_branches/ipp-20130419/pswarp/src/pswarpLoadAstrometry.c	(revision 35436)
+++ branches/eam_branches/ipp-20130419/pswarp/src/pswarpLoadAstrometry.c	(revision 35449)
@@ -98,7 +98,7 @@
     }
     // for pswarpLocalFrame, I need transformations and HDUs on a single fpa (so set on astrom as well as target)
-    target->fpa->toTPA = psMemIncrRefCounter (astrom->fpa->toTPA);
-    target->fpa->fromTPA = psMemIncrRefCounter (astrom->fpa->fromTPA);
-    target->fpa->toSky = psMemIncrRefCounter (astrom->fpa->toSky);
+    // target->fpa->toTPA = psMemIncrRefCounter (astrom->fpa->toTPA);
+    // target->fpa->fromTPA = psMemIncrRefCounter (astrom->fpa->fromTPA);
+    // target->fpa->toSky = psMemIncrRefCounter (astrom->fpa->toSky);
 
     while ((chip = pmFPAviewNextChip (view, astrom->fpa, 1)) != NULL) {
@@ -126,5 +126,5 @@
 	} else {
 	    // we use a default FPA pixel scale of 1.0
-	    if (!pmAstromReadWCS(target->fpa, chip, hdu->header, 1.0)) {
+	    if (!pmAstromReadWCS(astrom->fpa, chip, hdu->header, 1.0)) {
 		psError(psErrorCodeLast(), false, "Unable to read WCS astrometry for skycell.");
 		psFree(view);
@@ -136,4 +136,9 @@
     }
 
+    // for pswarpLocalFrame, I need transformations and HDUs on a single fpa (so set on astrom as well as target)
+    target->fpa->toTPA = psMemIncrRefCounter (astrom->fpa->toTPA);
+    target->fpa->fromTPA = psMemIncrRefCounter (astrom->fpa->fromTPA);
+    target->fpa->toSky = psMemIncrRefCounter (astrom->fpa->toSky);
+
     // reset the type to the original value
     astrom->type = saveType;
Index: branches/eam_branches/ipp-20130419/pswarp/src/pswarpLoopSkycell.c
===================================================================
--- branches/eam_branches/ipp-20130419/pswarp/src/pswarpLoopSkycell.c	(revision 35436)
+++ branches/eam_branches/ipp-20130419/pswarp/src/pswarpLoopSkycell.c	(revision 35449)
@@ -18,5 +18,5 @@
 
 // Loop over the inputs, warp them to the output skycell and then write out the output.
-bool pswarpLoop(pmConfig *config, psMetadata *stats)
+bool pswarpLoopSkycell(pmConfig *config, psMetadata *stats)
 {
     bool status;
Index: branches/eam_branches/ipp-20130419/pswarp/src/pswarpParseCamera.c
===================================================================
--- branches/eam_branches/ipp-20130419/pswarp/src/pswarpParseCamera.c	(revision 35436)
+++ branches/eam_branches/ipp-20130419/pswarp/src/pswarpParseCamera.c	(revision 35449)
@@ -78,5 +78,5 @@
         }
     }
-    if ((astrom->type != PM_FPA_FILE_CMF) && (astrom->type != PM_FPA_FILE_WCS)) {
+    if (astrom && (astrom->type != PM_FPA_FILE_CMF) && (astrom->type != PM_FPA_FILE_WCS)) {
 	psLogMsg("pswarp", PS_LOG_INFO, "%s is neither CMF nor WCS", "PSWARP.ASTROM");
     }
