Index: /trunk/psLib/src/sys/psAbort.c
===================================================================
--- /trunk/psLib/src/sys/psAbort.c	(revision 17445)
+++ /trunk/psLib/src/sys/psAbort.c	(revision 17446)
@@ -11,6 +11,6 @@
  *  @author Joshua Hoblitt, University of Hawaii
  *   
- *  @version $Revision: 1.15 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2007-02-07 23:52:54 $
+ *  @version $Revision: 1.16 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2008-04-13 08:18:27 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -49,2 +49,26 @@
     abort();
 }
+
+void p_psAssert(const char *file,
+		unsigned int lineno,
+		const char *func,
+		const bool value,
+		const char *format,
+		...)
+{
+    if (value) return;
+    psErrorStackPrint(stderr, "Aborting. Error stack:");
+
+    va_list argPtr;             // variable list arguement pointer
+    // Get the variable list parameters to pass to logging function
+    va_start(argPtr, format);
+
+    // Call logging function with PS_LOG_ABORT level
+    psLogMsgV("psLib.sys", PS_LOG_ABORT, format, argPtr);
+
+    // Clean up stack after variable arguement has been used
+    va_end(argPtr);
+
+    // Call system abort function to terminate program execution
+    abort();
+}
Index: /trunk/psLib/src/sys/psAbort.h
===================================================================
--- /trunk/psLib/src/sys/psAbort.h	(revision 17445)
+++ /trunk/psLib/src/sys/psAbort.h	(revision 17446)
@@ -10,6 +10,6 @@
  *  @author Joshua Hoblitt, University of Hawaii
  *
- *  $Revision: 1.15 $ $Name: not supported by cvs2svn $
- *  $Date: 2007-08-09 01:40:07 $
+ *  $Revision: 1.16 $ $Name: not supported by cvs2svn $
+ *  $Date: 2008-04-13 08:18:27 $
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
  */
@@ -54,4 +54,35 @@
 #endif // ifdef DOXYGEN
 
+/** Reports an abort message to logging facility
+ *
+ *  This function will invoke the psLogMsg function with a level of
+ *  PS_LOG_ABORT and pass the parameters name and fmt to generate a proper
+ *  log message.  After logging, this function will call system abort
+ *  function to abnormally terminate the program.
+ *
+ *  @return  void No return value
+ *
+ */
+#ifdef DOXYGEN
+void psAssert(
+    const bool value,
+    const char *format,                 ///< A printf style formatting statement
+    ...
+);
+#else // ifdef DOXYGEN
+void p_psAssert(
+    const char *file,                   ///< File of caller
+    unsigned int lineno,                ///< Line number of caller
+    const char *func,                   ///< Function name of caller
+    const bool value,
+    const char *format,                 ///< A printf style formatting statement
+    ...
+) PS_ATTR_FORMAT(printf, 5, 6);
+#ifndef SWIG
+#define psAssert(VALUE, ...) \
+      p_psAssert(__FILE__, __LINE__, __func__, (VALUE), __VA_ARGS__)
+#endif // iddef SWIG
+#endif // ifdef DOXYGEN
+
 /// @}
 #endif // #ifndef PS_ABORT_H
