Index: trunk/psLib/src/sysUtils/psMemory.h
===================================================================
--- trunk/psLib/src/sysUtils/psMemory.h	(revision 4401)
+++ trunk/psLib/src/sysUtils/psMemory.h	(revision 4444)
@@ -12,6 +12,6 @@
  *  @ingroup MemoryManagement
  *
- *  @version $Revision: 1.44 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2005-06-27 20:38:12 $
+ *  @version $Revision: 1.45 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2005-07-01 03:57:39 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -49,11 +49,11 @@
 
 /// typedef for memory identification numbers.  Guaranteed to be some variety of integer.
-typedef psU64 psMemId;
+typedef unsigned long psMemId;
 
 /// typedef for a memory block's reference count. Guaranteed to be some variety of integer.
-typedef psU64 psReferenceCount;
+typedef unsigned long psReferenceCount;
 
 /// typedef for deallocator.
-typedef void (*psFreeFunc) (psPtr ptr);
+typedef void (*psFreeFunc) (void* ptr);
 
 /** Book-keeping data for storage allocator.
@@ -64,5 +64,5 @@
 typedef struct psMemBlock
 {
-    const psPtr startblock;            ///< initialised to p_psMEMMAGIC
+    const void* startblock;            ///< initialised to p_psMEMMAGIC
     struct psMemBlock* previousBlock;  ///< previous block in allocation list
     struct psMemBlock* nextBlock;      ///< next block allocation list
@@ -71,9 +71,9 @@
     const psMemId id;                  ///< a unique ID for this allocation
     const char *file;                  ///< set from __FILE__ in e.g. p_psAlloc
-    const psS32 lineno;                ///< set from __LINE__ in e.g. p_psAlloc
+    const unsigned int lineno;         ///< set from __LINE__ in e.g. p_psAlloc
     pthread_mutex_t refCounterMutex;   ///< mutex to ensure exclusive access to reference counter
     psReferenceCount refCounter;       ///< how many times pointer is referenced
-    psBool persistent;                 ///< marks if this non-user persistent data like error stack, etc.
-    const psPtr endblock;              ///< initialised to p_psMEMMAGIC
+    bool persistent;                   ///< marks if this non-user persistent data like error stack, etc.
+    const void* endblock;              ///< initialised to p_psMEMMAGIC
 }
 psMemBlock;
@@ -81,8 +81,8 @@
 /** prototype of a basic callback used by memory functions
  *
- *  @see psMemAllocateCallbackSet
- *  @ingroup memCallback
- */
-typedef psMemId(*psMemAllocateCallback) (
+ *  @see psMemAllocCallbackSet
+ *  @ingroup memCallback
+ */
+typedef psMemId(*psMemAllocCallback) (
     const psMemBlock* ptr              ///< the psMemBlock just allocated
 );
@@ -105,7 +105,7 @@
  */
 typedef void (*psMemProblemCallback) (
-    const psMemBlock* ptr,             ///< the pointer to the problematic memory block.
-    const char *file,                  ///< the file in which the problem originated
-    psS32 lineno                         ///< the line number in which the problem originated
+    psMemBlock* ptr,                   ///< the pointer to the problematic memory block.
+    const char *filename,                    ///< the file in which the problem originated
+    unsigned int lineno                ///< the line number in which the problem originated
 );
 
@@ -118,5 +118,5 @@
  *  @ingroup memCallback
  */
-typedef psPtr (*psMemExhaustedCallback) (
+typedef void* (*psMemExhaustedCallback) (
     size_t size                        ///< the size of buffer required
 );
@@ -128,11 +128,15 @@
  */
 #ifdef DOXYGEN
-psPtr psAlloc(size_t size       ///< Size required
-             );
+
+psPtr psAlloc(
+    size_t size                        ///< Size required
+);
+
 #else // #ifdef DOXYGEN
-psPtr p_psAlloc(size_t size,    ///< Size required
-                const char *file,       ///< File of call
-                psS32 lineno      ///< Line number of call
-               );
+psPtr p_psAlloc(
+    size_t size,                       ///< Size required
+    const char *filename,              ///< File of call
+    unsigned int lineno                ///< Line number of call
+);
 
 /// Memory allocation. psAlloc sends file and line number to p_psAlloc.
@@ -203,14 +207,16 @@
  */
 #ifdef DOXYGEN
+
 psPtr psRealloc(
-    psPtr ptr,                          ///< Pointer to re-allocate
-    size_t size                         ///< Size required
+    psPtr ptr,                         ///< Pointer to re-allocate
+    size_t size                        ///< Size required
 );
 #else // #ifdef DOXYGEN
+
 psPtr p_psRealloc(
     psPtr ptr,                         ///< Pointer to re-allocate
     size_t size,                       ///< Size required
-    const char *file,                  ///< File of call
-    psS32 lineno                       ///< Line number of call
+    const char *filename,              ///< File of call
+    unsigned int lineno                ///< Line number of call
 );
 
@@ -234,5 +240,5 @@
     psPtr ptr,                         ///< Pointer to free
     const char *file,                  ///< File of call
-    psS32 lineno                       ///< Line number of call
+    unsigned int lineno                ///< Line number of call
 );
 
@@ -259,5 +265,5 @@
  */
 psS32 psMemCheckLeaks(
-    psMemId id0,                    ///< don't list blocks with id < id0
+    psMemId id0,                       ///< don't list blocks with id < id0
     psMemBlock* ** arr,                ///< pointer to array of pointers to leaked blocks, or NULL
     FILE * fd,                         ///< print list of leaks to fd (or NULL)
@@ -288,5 +294,5 @@
 #ifdef DOXYGEN
 psPtr psMemIncrRefCounter(
-    const psPtr ptr                         ///< Pointer to increment refCounter, and return
+    const psPtr ptr                    ///< Pointer to increment refCounter, and return
 );
 #else
@@ -294,5 +300,5 @@
     psPtr vptr,                        ///< Pointer to increment refCounter, and return
     const char *file,                  ///< File of call
-    psS32 lineno                         ///< Line number of call
+    psS32 lineno                       ///< Line number of call
 );
 
@@ -318,5 +324,5 @@
     psPtr vptr,                        ///< Pointer to decrement refCounter, and return
     const char *file,                  ///< File of call
-    psS32 lineno                         ///< Line number of call
+    psS32 lineno                       ///< Line number of call
 );
 
@@ -362,15 +368,15 @@
 /** Set call back for when a particular memory block is allocated
  *
- *  A private variable, p_psMemAllocateID, can be used to trace the allocation
- *  and freeing of specific memory blocks. If p_psMemAllocateID is set and a
- *  memory block with that ID is allocated, psMemAllocateCallback is called
+ *  A private variable, p_psMemAllocID, can be used to trace the allocation
+ *  and freeing of specific memory blocks. If p_psMemAllocID is set and a
+ *  memory block with that ID is allocated, psMemAllocCallback is called
  *  just before memory is returned to the calling function.
  *
  *  @ingroup memCallback
  *
- *  @return psMemAllocateCallback      old psMemAllocateCallback function
- */
-psMemAllocateCallback psMemAllocateCallbackSet(
-    psMemAllocateCallback func       ///< Function to run at memory allocation of specific mem block
+ *  @return psMemAllocCallback      old psMemAllocCallback function
+ */
+psMemAllocCallback psMemAllocCallbackSet(
+    psMemAllocCallback func            ///< Function to run at memory allocation of specific mem block
 );
 
@@ -398,9 +404,9 @@
 psMemId psMemGetId(void);
 
-/** set p_psMemAllocateID to specific id
- *
- *  A private variable, p_psMemAllocateID, can be used to trace the allocation
- *  and freeing of specific memory blocks. If p_psMemAllocateID is set and a
- *  memory block with that ID is allocated, psMemAllocateCallback is called
+/** set p_psMemAllocID to specific id
+ *
+ *  A private variable, p_psMemAllocID, can be used to trace the allocation
+ *  and freeing of specific memory blocks. If p_psMemAllocID is set and a
+ *  memory block with that ID is allocated, psMemAllocCallback is called
  *  just before memory is returned to the calling function.
  *
@@ -409,8 +415,8 @@
  *  @return psMemId
  *
- *  @see psMemAllocateCallbackSet
- */
-psMemId psMemAllocateCallbackSetID(
-    psMemId id                      ///< ID to set
+ *  @see psMemAllocCallbackSet
+ */
+psMemId psMemAllocCallbackSetID(
+    psMemId id                         ///< ID to set
 );
 
@@ -429,5 +435,5 @@
  */
 psMemId psMemFreeCallbackSetID(
-    psMemId id                      ///< ID to set
+    psMemId id                         ///< ID to set
 );
 
