Index: trunk/psLib/src/astro/psTime.c
===================================================================
--- trunk/psLib/src/astro/psTime.c	(revision 1864)
+++ trunk/psLib/src/astro/psTime.c	(revision 2001)
@@ -11,6 +11,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.24 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-09-23 18:31:49 $
+ *  @version $Revision: 1.25 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-10-07 19:16:46 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -67,5 +67,5 @@
                 }
 
-                /** Preprocessor macro to allocate psTime strict */
+                /** Preprocessor macro to allocate psTime struct */
                 #define ALLOC_TIME(TIME)                                                                                     \
                 TIME = (psTime*)psAlloc(sizeof(psTime));                                                                     \
@@ -469,5 +469,5 @@
     // Convert Universal Time (UTC) to  UT1
     ALLOC_TIME(ut1UtcDelta);
-    ALLOC_TIME(ut1Time);
+    // ALLOC_TIME(ut1Time);
     ut1UtcDelta->usec = psGetUT1Delta(utcTime)*1e6;
     ut1Time = psTimeAdd(utcTime, ut1UtcDelta);
@@ -479,5 +479,5 @@
 
     // Calculate Terrestial Dynamical Time (TDT)
-    ALLOC_TIME(tdtTime);
+    // ALLOC_TIME(tdtTime);
     ALLOC_TIME(tdtDelta);
     tdtDelta->sec = 32;
@@ -514,9 +514,15 @@
 double psGetUT1Delta(psTime *time)
 {
-    psImage *iersTable = NULL;
+    static psImage* iersTable = NULL;
     double ut1UtcDeltaUsec = 0.0;
 
 
-    iersTable = readSer7File("../../data/ser7.dat");
+    if (iersTable == NULL) {
+        iersTable = readSer7File("../../data/ser7.dat");
+        p_psMemSetPersistent(iersTable,true);
+        p_psMemSetPersistent(iersTable->data.V,true);
+        p_psMemSetPersistent(iersTable->rawDataBuffer,true);
+    }
+
     ut1UtcDeltaUsec = lookupSer7Table(iersTable, time, 6)*1.0e6;
 
@@ -527,8 +533,13 @@
 {
     double delta = 0.0;
-    psImage *taiUtcTable = NULL;
-
-
-    taiUtcTable = readTaiUtcFile("../../data/tai-utc.dat");
+    static psImage* taiUtcTable = NULL;
+
+
+    if (taiUtcTable == NULL) {
+        taiUtcTable = readTaiUtcFile("../../data/tai-utc.dat");
+        p_psMemSetPersistent(taiUtcTable,true);
+        p_psMemSetPersistent(taiUtcTable->data.V,true);
+        p_psMemSetPersistent(taiUtcTable->rawDataBuffer,true);
+    }
     delta = lookupTaiUtcTable(taiUtcTable, time);
 
