Index: trunk/psLib/test/collections/tst_psHash04.c
===================================================================
--- trunk/psLib/test/collections/tst_psHash04.c	(revision 2392)
+++ trunk/psLib/test/collections/tst_psHash04.c	(revision 2626)
@@ -47,8 +47,5 @@
     ID* id = NULL;
 
-    printPositiveTestHeader(stdout,
-                            "psHash functions",
-                            "psHashKeyList()");
-
+    printPositiveTestHeader(stdout,"psHash functions","psHashKeyList()");
     myHashTable = psHashAlloc(NUM_HASH_TABLE_BUCKETS);
     i = 0;
@@ -65,16 +62,19 @@
         tmp = tmp->next;
     }
-
+    printFooter(stdout,"psHash functions","psHashKeyList()",testStatus);
     psFree(myLinkList);
 
-    printFooter(stdout,
-                "psHash functions",
-                "psHashKeyList()",
-                testStatus);
+    printNegativeTestHeader(stdout,"psHashKeyList","NULL table","Can not lookup with NULL table",0);
+    myLinkList = psHashKeyList(NULL);
+    if(myLinkList != NULL) {
+        psError(PS_ERR_UNKNOWN,true,"psHashKeyList retrieved a key list from a NULL table.");
+        return 1;
+    }
+    printFooter(stdout,"psHashKeyList","NULL table",true);
 
     psFree(myHashTable);
 
     memLeaks = psMemCheckLeaks(currentId,NULL,stderr,false);
-    if (0 != memLeaks) {
+    if (memLeaks != 0) {
         psAbort(__func__,"Memory Leaks! (%d leaks)", memLeaks);
     }
