Index: /trunk/Ohana/src/addstar/src/get2mass_ops.c
===================================================================
--- /trunk/Ohana/src/addstar/src/get2mass_ops.c	(revision 17195)
+++ /trunk/Ohana/src/addstar/src/get2mass_ops.c	(revision 17196)
@@ -256,2 +256,15 @@
   return (sky);
 }
+
+int get2mass_sortStars (TMStars *tstars, int Ntstars) {
+
+# define SWAPFUNC(A,B){ TMStars temp = tstars[A]; tstars[A] = tstars[B]; tstars[B] = temp; }
+# define COMPARE(A,B)(tstars[A].R < tstars[B].R)
+
+  OHANA_SORT (Ntstars, COMPARE, SWAPFUNC);
+
+# undef SWAPFUNC
+# undef COMPARE
+  
+  return TRUE;
+}
