This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: g77/F90 date_and_time() intrinsic


>>>>> "KM" == Kevin Maguire <K.Maguire@dl.ac.uk> writes:

 KM> So don't we need to convert this to milliseconds to satisfy the
 KM> standard.

Trusting that I don't need approval, I installed this.  (The scopy
tidy-up has been waiting for a while).  It should probably go on the
release branch if there's ever a 1.1.2.

1999-01-15  Dave Love  <fx@gnu.org>

	* libU77/datetime_.c (G77_date_and_time_0): Return milliseconds as
	such, not as microseconds.
	(scopy): Declare.


Index: libf2c/libU77/datetime_.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/libf2c/libU77/datetime_.c,v
retrieving revision 1.1
diff -u -p -u -r1.1 datetime_.c
--- datetime_.c	1998/07/06 09:03:28	1.1
+++ datetime_.c	1999/01/15 14:31:23
@@ -32,6 +32,12 @@ Boston, MA 02111-1307, USA.  */
 #endif
 #include "f2c.h"
 
+#ifdef KR_headers
+VOID s_copy ();
+#else
+void s_copy(register char *a, register char *b, ftnlen la, ftnlen lb);
+#endif
+
 int G77_date_and_time_0 (char *date, char *fftime, char *zone,
 			 integer *values, ftnlen date_len,
 			 ftnlen fftime_len, ftnlen zone_len)
@@ -58,7 +64,7 @@ int G77_date_and_time_0 (char *date, cha
     struct timeval tp;
     struct timezone tzp;
     if (! gettimeofday (&tp, &tzp))
-      vals[7] = tp.tv_usec;
+      vals[7] = tp.tv_usec/1000;
   }
 #endif
   if (values)			/* null pointer for missing optional */


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]