Index: trunk/psLib/src/collections/psBitSet.c
===================================================================
--- trunk/psLib/src/collections/psBitSet.c	(revision 1063)
+++ trunk/psLib/src/collections/psBitSet.c	(revision 1073)
@@ -10,6 +10,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-15 02:45:43 $
+ *  @version $Revision: 1.8 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -55,4 +55,6 @@
 /*  FUNCTION IMPLEMENTATION - LOCAL                                          */
 /*****************************************************************************/
+static void bitSetFree(psBitSet *restrict inBitSet);
+
 
 /** Private function to create a mask.
@@ -88,4 +90,5 @@
     numBytes = ceil(n/8.0);
     newObj = psAlloc(sizeof(psBitSet));
+    p_psMemSetDeallocator(newObj,(psFreeFcn)bitSetFree);
     newObj->n = numBytes;
 
@@ -98,5 +101,5 @@
 }
 
-void psBitSetFree(psBitSet *restrict inBitSet)
+static void bitSetFree(psBitSet *restrict inBitSet)
 {
     if(inBitSet == NULL) {
@@ -105,5 +108,4 @@
     }
     psFree(inBitSet->bits);
-    psFree(inBitSet);
 }
 
Index: trunk/psLib/src/collections/psBitSet.h
===================================================================
--- trunk/psLib/src/collections/psBitSet.h	(revision 1063)
+++ trunk/psLib/src/collections/psBitSet.h	(revision 1073)
@@ -12,6 +12,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-10 01:58:06 $
+ *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -54,12 +54,4 @@
 psBitSet* psBitSetAlloc(
     int n   /**< Number of bits in psBitSet array */
-);
-
-/** Free a psBitSet
- *
- *  Deletes a psBitSet array.
- */
-void psBitSetFree(
-    psBitSet *restrict inMask  /**< Pointer to psBitSet to be deleted. */
 );
 
Index: trunk/psLib/src/collections/psList.c
===================================================================
--- trunk/psLib/src/collections/psList.c	(revision 1063)
+++ trunk/psLib/src/collections/psList.c	(revision 1073)
@@ -6,6 +6,6 @@
  *  @author Robert Daniel DeSonia, MHPCC
  *
- *  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-14 19:45:46 $
+ *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -28,7 +28,8 @@
 
 // private functions.
-psListElem* listGetIterator(psList* list);
-int listGetIteratorIndex(psList* list);
-void listSetIterator(psList *list, int where, bool lockList);
+static psListElem* listGetIterator(psList* list);
+static int listGetIteratorIndex(psList* list);
+static void listSetIterator(psList *list, int where, bool lockList);
+static void listFree(psList *list);
 
 
@@ -36,4 +37,5 @@
 {
     psList *list = psAlloc(sizeof(psList));
+    p_psMemSetDeallocator(list,(psFreeFcn)listFree);
 
     list->size = 0;
@@ -41,4 +43,5 @@
     list->iter = ITER_INIT_HEAD;
     list->iterIndex = PS_LIST_HEAD;
+
     pthread_mutex_init(&(list->lock),NULL)
     ;
@@ -51,5 +54,5 @@
 }
 
-void psListFree(psList *list, psFreeFcn elemFree)
+static void listFree(psList *list)
 {
     if (list == NULL) {
@@ -63,5 +66,5 @@
         psListElem *next = ptr->next;
 
-        p_psCustomFree(elemFree, psMemDecrRefCounter(ptr->data));
+        psFree(ptr->data);
         psFree(ptr);
 
@@ -75,5 +78,4 @@
     ;
 
-    psFree(list);
 }
 
Index: trunk/psLib/src/collections/psList.h
===================================================================
--- trunk/psLib/src/collections/psList.h	(revision 1063)
+++ trunk/psLib/src/collections/psList.h	(revision 1073)
@@ -10,6 +10,6 @@
  *  @ingroup LinkedList
  *
- *  @version $Revision: 1.4 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-12 22:15:39 $
+ *  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -73,15 +73,4 @@
 )
 ;
-
-#include "psMemory.h"
-/** Destroys a psList linked list object.  This also frees the elements of the
- *  list using the psFreeFcn given, if any.  If no psFreeFcn is specified,
- *  the elements are just dereferenced via psMemDecrRefCounter(...).
- *
- */
-void psListFree(
-    psList* restrict list,              ///< list to destroy
-    psFreeFcn elemFree                  ///< destructor for data on list
-);
 
 /** Adds an element to a psList at position given.
Index: trunk/psLib/src/collections/psSort.c
===================================================================
--- trunk/psLib/src/collections/psSort.c	(revision 1063)
+++ trunk/psLib/src/collections/psSort.c	(revision 1073)
@@ -14,6 +14,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-10 23:15:08 $
+ *  @version $Revision: 1.12 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -33,4 +33,5 @@
 #include "psSort.h"
 #include "psError.h"
+#include "psMemory.h"
 
 /******************************************************************************/
@@ -242,5 +243,5 @@
 
     // Free temp memory
-    psVectorFree(tmpVector);
+    psFree(tmpVector);
 
     return outVector;
Index: trunk/psLib/src/collections/psSort.d
===================================================================
--- trunk/psLib/src/collections/psSort.d	(revision 1063)
+++ trunk/psLib/src/collections/psSort.d	(revision 1073)
@@ -1,1 +1,2 @@
-psSort.o psSort.d : psSort.c psVector.h psType.h psSort.h ../sysUtils/psError.h
+psSort.o psSort.d : psSort.c psVector.h psType.h psSort.h ../sysUtils/psError.h \
+  ../sysUtils/psMemory.h
Index: trunk/psLib/src/collections/psVector.c
===================================================================
--- trunk/psLib/src/collections/psVector.c	(revision 1063)
+++ trunk/psLib/src/collections/psVector.c	(revision 1073)
@@ -8,6 +8,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.10 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-12 01:33:16 $
+ *  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -49,4 +49,5 @@
 /*  FUNCTION IMPLEMENTATION - LOCAL                                          */
 /*****************************************************************************/
+static void vectorFree(psVector *restrict psVec);
 
 /*****************************************************************************/
@@ -68,4 +69,5 @@
     // Create vector struct
     psVec = (psVector *)psAlloc(sizeof(psVector));
+    p_psMemSetDeallocator(psVec,(psFreeFcn)vectorFree);
 
     psVec->type.dimen = PS_DIMEN_VECTOR;
@@ -132,5 +134,5 @@
     if(nalloc < 1) {
         psError(__func__, "Invalid value for nalloc (%d)\n", nalloc);
-        psVectorFree(in);
+        psFree(in);
         return NULL;
     }
@@ -154,5 +156,5 @@
 }
 
-void psVectorFree(psVector *restrict psVec)
+static void vectorFree(psVector *restrict psVec)
 {
     if (psVec == NULL) {
@@ -160,9 +162,15 @@
     }
 
+    if (psVec->type.type == PS_TYPE_PTR) {
+        for(int i = 0; i < psVec->n; i++) {
+            psFree(psVec->data.PTR[i]);
+            psVec->data.PTR[i] = NULL;
+        }
+    }
+
     psFree(psVec->data.V);
-    psFree(psVec);
 }
 
-void psVectorElementFree(psVector *restrict psVec, void (*elemFree)(void *))
+void psVectorElementFree(psVector *restrict psVec)
 {
 
@@ -176,10 +184,6 @@
     }
 
-    for(int i = 0; i < psVec->nalloc; i++) {
-        if(elemFree == NULL) {
-            psMemDecrRefCounter(psVec->data.PTR[i]);
-        } else {
-            elemFree(psMemDecrRefCounter(psVec->data.PTR[i]));
-        }
+    for(int i = 0; i < psVec->n; i++) {
+        psFree(psVec->data.PTR[i]);
         psVec->data.PTR[i] = NULL;
     }
Index: trunk/psLib/src/collections/psVector.h
===================================================================
--- trunk/psLib/src/collections/psVector.h	(revision 1063)
+++ trunk/psLib/src/collections/psVector.h	(revision 1073)
@@ -11,6 +11,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.10 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-06-10 01:58:06 $
+ *  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-23 23:00:15 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -100,17 +100,4 @@
 );
 
-/** Deallocate a vector.
- *
- * Uses psLib memory allocation functions to deallocate a vector collection of data. The vector is deallocated
- * according to the psType type member contained within the vector.
- *
- * @return psVector*: Pointer to psVector.
- *
- */
-void psVectorFree(
-    psVector *restrict psVec  ///< Vector to free.
-);
-
-
 /** Deallocate/Dereference elements of a void pointer vector.
  *
@@ -122,6 +109,5 @@
  */
 void psVectorElementFree(
-    psVector *restrict psVec,   ///< Void pointer vector to destroy.
-    void (*elemFree)(void *)    ///< Optional callback function to remove vector elements.
+    psVector *restrict psVec    ///< Void pointer vector to destroy.
 );
 
