Index: trunk/psModules/src/objects/pmPeaks.c
===================================================================
--- trunk/psModules/src/objects/pmPeaks.c	(revision 6943)
+++ trunk/psModules/src/objects/pmPeaks.c	(revision 7311)
@@ -6,6 +6,6 @@
  *  @author EAM, IfA: significant modifications.
  *
- *  @version $Revision: 1.3 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2006-04-21 21:26:44 $
+ *  @version $Revision: 1.4 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2006-06-03 01:02:08 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -94,4 +94,7 @@
 pmPeakAlloc(): Allocate the pmPeak data structure and set appropriate members.
 *****************************************************************************/
+static void peakFree(pmPeak *tmp)
+{} // used by pmIsPeak()
+
 pmPeak *pmPeakAlloc(psS32 x,
                     psS32 y,
@@ -100,5 +103,7 @@
 {
     psTrace(__func__, 3, "---- %s() begin ----\n", __func__);
+    static int id = 1;
     pmPeak *tmp = (pmPeak *) psAlloc(sizeof(pmPeak));
+    *(int *)&tmp->id = id++;
     tmp->x = x;
     tmp->y = y;
@@ -106,6 +111,13 @@
     tmp->type = type;
 
+    psMemSetDeallocator(tmp, (psFreeFunc) peakFree);
+
     psTrace(__func__, 3, "---- %s() end ----\n", __func__);
     return(tmp);
+}
+
+bool pmIsPeak(const psPtr ptr)
+{
+    return (psMemGetDeallocator(ptr) == (psFreeFunc)peakFree);
 }
 
