Index: /trunk/psLib/src/math/psSpline.c
===================================================================
--- /trunk/psLib/src/math/psSpline.c	(revision 5071)
+++ /trunk/psLib/src/math/psSpline.c	(revision 5072)
@@ -7,6 +7,6 @@
 *  splines.
 *
-*  @version $Revision: 1.125 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2005-09-19 22:50:28 $
+*  @version $Revision: 1.126 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2005-09-20 02:43:53 $
 *
 *
@@ -43,6 +43,6 @@
 /*****************************************************************************/
 static void spline1DFree(psSpline1D *tmpSpline);
-static unsigned int vectorBinDisectF32(psF32 *bins,psS32 numBins,psF32 x);
-static unsigned int vectorBinDisectS32(psS32 *bins,psS32 numBins,psS32 x);
+static unsigned int vectorBinDisectF32(psF32 *bins,unsigned int numBins,psF32 x);
+static unsigned int vectorBinDisectS32(psS32 *bins,unsigned int numBins,psS32 x);
 
 /*****************************************************************************/
@@ -113,5 +113,5 @@
     \
     psTrace(".psLib.dataManip.psSpline.fullInterpolate1D##TYPE", 4, \
-            "---- fullInterpolate1D##TYPE() begin (%d-order at x=%f) (%d data points)----\n", n-1, x, n); \
+            "---- fullInterpolate1D##TYPE() begin (%u-order at x=%f) (%d data points)----\n", n-1, x, n); \
     \
     for (i=0;i<n;i++) { \
@@ -123,5 +123,5 @@
         p->data.TYPE[i] = range[i]; \
         psTrace(".psLib.dataManip.psSpline.fullInterpolate1D##TYPE", 6, \
-                "p->data.TYPE[%d] is %f\n", i, p->data.TYPE[i]); \
+                "p->data.TYPE[%u] is %f\n", i, p->data.TYPE[i]); \
         \
     } \
@@ -140,5 +140,5 @@
              */ \
             psTrace(".psLib.dataManip.psSpline.fullInterpolate1D##TYPE", 6, \
-                    "p->data.TYPE[%d] is %f\n", i, p->data.TYPE[i]); \
+                    "p->data.TYPE[%u] is %f\n", i, p->data.TYPE[i]); \
         } \
     } \
@@ -841,10 +841,10 @@
 #define FUNC_MACRO_VECTOR_BIN_DISECT(TYPE) \
 static unsigned int vectorBinDisect##TYPE(ps##TYPE *bins, \
-        psS32 numBins, \
+        unsigned int numBins, \
         ps##TYPE x) \
 { \
-    psS32 min; \
-    psS32 max; \
-    psS32 mid; \
+    unsigned int min; \
+    unsigned int max; \
+    unsigned int mid; \
     \
     psTrace(".psLib.dataManip.psSpline.vectorBinDisect##TYPE", 4, \
@@ -871,10 +871,10 @@
     while (min != max) { \
         psTrace(".psLib.dataManip.psSpline.vectorBinDisect##TYPE", 4, \
-                "(min, mid, max) is (%d, %d, %d): (x, bins) is (%f, %f)\n", \
+                "(min, mid, max) is (%u, %u, %u): (x, bins) is (%f, %f)\n", \
                 min, mid, max, x, bins[mid]); \
         \
         if (x == bins[mid]) { \
             psTrace(".psLib.dataManip.psSpline.vectorBinDisect##TYPE", 4, \
-                    "---- Exiting vectorBinDisect##TYPE(): bin %d\n", mid); \
+                    "---- Exiting vectorBinDisect##TYPE(): bin %u\n", mid); \
             return(mid); \
         } else if (x < bins[mid]) { \
@@ -887,5 +887,5 @@
     \
     psTrace(".psLib.dataManip.psSpline.vectorBinDisect##TYPE", 4, \
-            "---- Exiting vectorBinDisect##TYPE(): bin %d\n", min); \
+            "---- Exiting vectorBinDisect##TYPE(): bin %u\n", min); \
     return(min); \
 } \
Index: /trunk/psLib/src/sys/psLogMsg.c
===================================================================
--- /trunk/psLib/src/sys/psLogMsg.c	(revision 5071)
+++ /trunk/psLib/src/sys/psLogMsg.c	(revision 5072)
@@ -12,6 +12,6 @@
  *  @author GLG, MHPCC
  *
- *  @version $Revision: 1.51 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2005-09-09 01:11:22 $
+ *  @version $Revision: 1.52 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2005-09-20 02:43:53 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -51,4 +51,5 @@
 
 static FILE *logDest = (FILE *) 1;      // flag to initialize to stderr before using.
+static int logFD = 0;
 static psS32 globalLogLevel = PS_LOG_INFO;        // log all messages at this or above
 static psBool logTime = true;     // Flag to include time info
@@ -81,4 +82,9 @@
 }
 
+int psLogGetLevel()
+{
+    return (globalLogLevel);
+}
+
 /*****************************************************************************
 psLogSetDestination(): sets the log message destination.
@@ -94,4 +100,5 @@
     if (logDest == (FILE *) 1) {
         logDest = stderr;
+        logFD = 2;
     }
     if (fd == -1)
@@ -104,4 +111,5 @@
         }
         logDest = stdout;
+        logFD = 1;
     } else if (fd == 2) {
         //        fp = stderr;
@@ -110,4 +118,5 @@
         }
         logDest = stderr;
+        logFD = 2;
     } else if (fd == 0) {
         //        fp = NULL;
@@ -116,4 +125,5 @@
         }
         logDest = NULL;
+        logFD = 0;
         //        return true;
     } else if (fd > 2) {
@@ -123,4 +133,5 @@
         fp = fdopen(fd, "w");
         logDest = fp;
+        logFD = fd;
         //        fclose(fp);
         //        return true;
@@ -130,4 +141,13 @@
 
 }
+
+int psLogGetDestination(void)
+{
+    if (logDest == (FILE *) 1) {
+        logFD = 1;
+    }
+    return (logFD);
+}
+
 
 /*****************************************************************************
Index: /trunk/psLib/src/sys/psLogMsg.h
===================================================================
--- /trunk/psLib/src/sys/psLogMsg.h	(revision 5071)
+++ /trunk/psLib/src/sys/psLogMsg.h	(revision 5072)
@@ -11,6 +11,6 @@
  *  @author GLG, MHPCC
  *
- *  @version $Revision: 1.33 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2005-09-15 21:22:22 $
+ *  @version $Revision: 1.34 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2005-09-20 02:43:53 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -36,4 +36,11 @@
 );
 
+/** This procedure returns the current log destination file descriptor.  If the
+ *  destination has not been defined by the use, the descriptor for stdout is returned.
+ *
+ *  @return int:        The current file descriptor.
+ */
+int psLogGetDestination();
+
 /** This procedure sets the message level for future log messages.  Subsequent
  *  log messages, with a log level of "mylevel", will only be logged if
@@ -42,9 +49,15 @@
  *  be displayed.  The old log level will be returned.
  *
- *  @return int    old logging level
+ *  @return int:        old logging level.
  */
 int psLogSetLevel(
     int level                          ///< Specifies the system log level
 );
+
+/** This procedures returns the current log message level.
+ *
+ *  @return int:        The current logging level.
+ */
+int psLogGetLevel();
 
 /** This procedure sets the log format for future log messages.  The argument
Index: /trunk/psLib/test/sys/tst_psLogMsg.c
===================================================================
--- /trunk/psLib/test/sys/tst_psLogMsg.c	(revision 5071)
+++ /trunk/psLib/test/sys/tst_psLogMsg.c	(revision 5072)
@@ -26,5 +26,5 @@
                               },
                               {
-                                  testLogMsg02, 2, "psLogSetLevel()", 0, false
+                                  testLogMsg02, 2, "psLogSet/GetLevel()", 0, false
                               },
                               {
@@ -35,5 +35,5 @@
                               },
                               {
-                                  testLogMsg05, 5, "psLogSetDestination()", 0, false
+                                  testLogMsg05, 5, "psLogSet/GetDestination()", 0, false
                               },
                               {
@@ -107,4 +107,5 @@
     psLogSetLevel(4);
     psLogMsg(__func__, 4, "This should  be displayed (level %d)\n", 4);
+    psLogMsg(__func__, 4, "This should display level 4 logging -> level %d\n", psLogGetLevel() );
 
     return 0;
@@ -189,4 +190,5 @@
     //    psLogSetDestination("none");
     psLogSetDestination(0);
+    printf("    File Descriptor = %d \n", psLogGetDestination() );
     for (i=0;i<10;i++) {
         psLogMsg(__func__, i, "Hello World!  My level is %d\n", i);
@@ -196,4 +198,5 @@
     //    psLogSetDestination("dest:stderr");
     psLogSetDestination(2);
+    printf("    File Descriptor = %d \n", psLogGetDestination() );
     for (i=0;i<10;i++) {
         psLogMsg(__func__, i, "Hello World!  My level is %d\n", i);
@@ -203,4 +206,5 @@
     //    psLogSetDestination("dest:stdout");
     psLogSetDestination(1);
+    printf("    File Descriptor = %d \n", psLogGetDestination() );
     for (i=0;i<10;i++) {
         psLogMsg(__func__, i, "Hello World!  My level is %d\n", i);
@@ -211,4 +215,5 @@
     //    psLogSetDestination("file:log.txt");
     psLogSetDestination(fd);
+    printf("    File Descriptor = %d \n", psLogGetDestination() );
     for (i=0;i<10;i++) {
         psLogMsg(__func__, i, "Hello World!  My level is %d\n", i);
Index: /trunk/psLib/test/sys/verified/tst_psLogMsg.stderr
===================================================================
--- /trunk/psLib/test/sys/verified/tst_psLogMsg.stderr	(revision 5071)
+++ /trunk/psLib/test/sys/verified/tst_psLogMsg.stderr	(revision 5072)
@@ -35,5 +35,5 @@
 /***************************** TESTPOINT ******************************************\
 *             TestFile: tst_psLogMsg.c                                             *
-*            TestPoint: psLogMsg{psLogSetLevel()}                                  *
+*            TestPoint: psLogMsg{psLogSet/GetLevel()}                              *
 *             TestType: Positive                                                   *
 \**********************************************************************************/
@@ -61,6 +61,8 @@
 <DATE><TIME>|<HOST>|4|testLogMsg02
     This should  be displayed (level 4)
+<DATE><TIME>|<HOST>|4|testLogMsg02
+    This should display level 4 logging -> level 4
 
----> TESTPOINT PASSED (psLogMsg{psLogSetLevel()} | tst_psLogMsg.c)
+---> TESTPOINT PASSED (psLogMsg{psLogSet/GetLevel()} | tst_psLogMsg.c)
 
 /***************************** TESTPOINT ******************************************\
@@ -152,5 +154,5 @@
 /***************************** TESTPOINT ******************************************\
 *             TestFile: tst_psLogMsg.c                                             *
-*            TestPoint: psLogMsg{psLogSetDestination()}                            *
+*            TestPoint: psLogMsg{psLogSet/GetDestination()}                        *
 *             TestType: Positive                                                   *
 \**********************************************************************************/
@@ -165,5 +167,5 @@
     Hello World!  My level is 3
 
----> TESTPOINT PASSED (psLogMsg{psLogSetDestination()} | tst_psLogMsg.c)
+---> TESTPOINT PASSED (psLogMsg{psLogSet/GetDestination()} | tst_psLogMsg.c)
 
 /***************************** TESTPOINT ******************************************\
Index: /trunk/psLib/test/sys/verified/tst_psLogMsg.stdout
===================================================================
--- /trunk/psLib/test/sys/verified/tst_psLogMsg.stdout	(revision 5071)
+++ /trunk/psLib/test/sys/verified/tst_psLogMsg.stdout	(revision 5072)
@@ -1,5 +1,8 @@
 --------------- psLogSetDestination(PS_LOG_NONE) ----------------
+    File Descriptor = 0 
 ------------- psLogSetDestination(PS_LOG_TO_STDERR) -------------
+    File Descriptor = 2 
 ------------- psLogSetDestination(PS_LOG_TO_STDOUT) -------------
+    File Descriptor = 1 
 <DATE><TIME>|<HOST>|A|testLogMsg05
     Hello World!  My level is 0
@@ -11,4 +14,5 @@
     Hello World!  My level is 3
 --------------- psLogSetDestination(file:log.txt) ---------------
+    File Descriptor = 3 
 --------------------- The Contents of log.txt -------------------
 <DATE><TIME>|<HOST>|A|testLogMsg05
