Index: /trunk/Ohana/src/gastro2/src/sort.c
===================================================================
--- /trunk/Ohana/src/gastro2/src/sort.c	(revision 7993)
+++ /trunk/Ohana/src/gastro2/src/sort.c	(revision 7994)
@@ -6,4 +6,6 @@
   double tX, tY, tR;
   
+  if (N < 2) return;
+
   l = N >> 1;
   ir = N - 1;
@@ -52,4 +54,6 @@
   double tX, tY, tS;
   
+  if (N < 2) return;
+
   l = N >> 1;
   ir = N - 1;
@@ -95,4 +99,6 @@
 void sort (double *X, int N) {
 
+  if (N < 2) return;
+
   int l,j,ir,i;
   double tmp;
@@ -132,4 +138,6 @@
   StarData tempstar;
   
+  if (N < 2) return;
+
   l = N >> 1;
   ir = N - 1;
@@ -165,4 +173,6 @@
   StarData tempstar;
   
+  if (N < 2) return;
+
   l = N >> 1;
   ir = N - 1;
