Index: trunk/Ohana/src/opihi/dvo/gstar.c
===================================================================
--- trunk/Ohana/src/opihi/dvo/gstar.c	(revision 6642)
+++ trunk/Ohana/src/opihi/dvo/gstar.c	(revision 6683)
@@ -72,8 +72,8 @@
   catalog.filename = skylist[0].filename[0];
   switch (lock_catalog (&catalog, LCK_SOFT)) {
-  case 2:
-    unlock_catalog (&catalog);
-  case 0:
-    return (FALSE);
+    case 2:
+      unlock_catalog (&catalog);
+    case 0:
+      return (FALSE);
   }
   catalog.catflags = LOAD_AVES | LOAD_MEAS | LOAD_SECF;
@@ -92,6 +92,6 @@
   /* stars are not guaranteed to be sorted in RA or in DEC, so first sort the list */
   for (i = 0; i < Nstars; i++) {
-    RA[i] = catalog.average[i].R_PS;
-    DEC[i] = catalog.average[i].D_PS;
+    RA[i] = catalog.average[i].R;
+    DEC[i] = catalog.average[i].D;
     N1[i] = i;
   }
@@ -138,30 +138,30 @@
       k = N1[i];
       if (!QUIET) {
-	  fprintf (GetOutfile(), "star: %d\n", k);
-	  fprintf (GetOutfile(), "%9.5f %9.5f %3d of %3d  %4.1f %5d\n", catalog.average[k].R_PS, catalog.average[k].D_PS, 
-		   catalog.average[k].Nm, catalog.average[k].Nn + catalog.average[k].Nm,
-		   0.01*catalog.average[k].Xp, catalog.average[k].code);
+	fprintf (GetOutfile(), "star: %d\n", k);
+	fprintf (GetOutfile(), "%9.5f %9.5f %3d of %3d  %4.1f %5d\n", catalog.average[k].R, catalog.average[k].D, 
+		 catalog.average[k].Nm, catalog.average[k].Nn + catalog.average[k].Nm,
+		 0.01*catalog.average[k].Xp, catalog.average[k].code);
       
-	  /* filter names -- primary code is 0 in this function */
-	  for (j = 0; j < Nsec + 1; j++) {
-	      code = GetPhotcodebyNsec (j);
-	      fprintf (GetOutfile (), "%s ", code[0].name);
-	  }
-	  fprintf (GetOutfile (), "\n");
-
-	  /* average mags */
-	  print_value (GetOutfile(), catalog.average[k].M_PS, catalog.average[k].M_PS);
-	  for (j = 0; j < Nsec; j++) print_value (GetOutfile(), catalog.secfilt[j + Nsec*k].M_PS, catalog.secfilt[j + Nsec*k].M_PS);
-	  fprintf (GetOutfile(), "\n");
-
-	  /* average mag errors */
-	  print_value (GetOutfile(), catalog.average[k].dM_PS, catalog.average[k].dM_PS);
-	  for (j = 0; j < Nsec; j++) print_value (GetOutfile(), catalog.secfilt[j + Nsec*k].dM_PS, catalog.secfilt[j + Nsec*k].dM_PS);
-	  fprintf (GetOutfile(), "\n");
-
-	  /* average mag chisq */
-	  print_value (GetOutfile(), pow (10.0, 0.01*catalog.average[k].Xm), catalog.average[k].Xm);
-	  for (j = 0; j < Nsec; j++) print_value (GetOutfile(), pow (10.0, 0.01*catalog.secfilt[j + Nsec*k].Xm), catalog.secfilt[j + Nsec*k].Xm);
-	  fprintf (GetOutfile(), "\n");
+	/* filter names -- primary code is 0 in this function */
+	for (j = 0; j < Nsec + 1; j++) {
+	  code = GetPhotcodebyNsec (j);
+	  fprintf (GetOutfile (), "%s ", code[0].name);
+	}
+	fprintf (GetOutfile (), "\n");
+
+	/* average mags */
+	print_value (GetOutfile(), catalog.average[k].M, catalog.average[k].M);
+	for (j = 0; j < Nsec; j++) print_value (GetOutfile(), catalog.secfilt[j + Nsec*k].M_PS, catalog.secfilt[j + Nsec*k].M_PS);
+	fprintf (GetOutfile(), "\n");
+
+	/* average mag errors */
+	print_value (GetOutfile(), catalog.average[k].dM, catalog.average[k].dM);
+	for (j = 0; j < Nsec; j++) print_value (GetOutfile(), catalog.secfilt[j + Nsec*k].dM_PS, catalog.secfilt[j + Nsec*k].dM_PS);
+	fprintf (GetOutfile(), "\n");
+
+	/* average mag chisq */
+	print_value (GetOutfile(), pow (10.0, 0.01*catalog.average[k].Xm), catalog.average[k].Xm);
+	for (j = 0; j < Nsec; j++) print_value (GetOutfile(), pow (10.0, 0.01*catalog.secfilt[j + Nsec*k].Xm), catalog.secfilt[j + Nsec*k].Xm);
+	fprintf (GetOutfile(), "\n");
       }
 
