Index: trunk/psModules/src/objects/pmSourceMatch.c
===================================================================
--- trunk/psModules/src/objects/pmSourceMatch.c	(revision 27333)
+++ trunk/psModules/src/objects/pmSourceMatch.c	(revision 28119)
@@ -280,4 +280,9 @@
     psFree(boundsMaster);
 
+    if (!matches) {
+        psError(PM_ERR_OBJECTS, true, "No matches made.");
+        return NULL;
+    }
+
     if (cullSingles) {
         // Now cull the matches that contain only a single star
@@ -300,4 +305,10 @@
     }
 
+    if (matches->n == 0) {
+        psError(PM_ERR_OBJECTS, true, "No matches made.");
+        psFree(matches);
+        return NULL;
+    }
+
     return matches;
 }
@@ -311,5 +322,5 @@
     psArray *matches = pmSourceMatchSources(sourceArrays, radius, false); // Source matches
     if (!matches) {
-        psError(PS_ERR_UNKNOWN, false, "Unable to match source lists.");
+        psError(psErrorCodeLast(), false, "Unable to match source lists.");
         return NULL;
     }
