svn commit: samba r4669 - in branches/SAMBA_4_0/source/lib: .
tridge at samba.org
tridge at samba.org
Tue Jan 11 03:07:54 GMT 2005
Author: tridge
Date: 2005-01-11 03:07:53 +0000 (Tue, 11 Jan 2005)
New Revision: 4669
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=4669
Log:
a timeval_to_nttime() function as requested by abartlet. Andrew, its
your responsibility to use/test this :-)
Modified:
branches/SAMBA_4_0/source/lib/time.c
Changeset:
Modified: branches/SAMBA_4_0/source/lib/time.c
===================================================================
--- branches/SAMBA_4_0/source/lib/time.c 2005-01-11 02:53:00 UTC (rev 4668)
+++ branches/SAMBA_4_0/source/lib/time.c 2005-01-11 03:07:53 UTC (rev 4669)
@@ -536,3 +536,13 @@
}
return t;
}
+
+
+/*
+ convert a timeval to a NTTIME
+*/
+NTTIME timeval_to_nttime(struct timeval *tv)
+{
+ double t1 = tv->tv_sec + (tv->tv_usec*1.0e-6);
+ return (t1 + TIME_FIXUP_CONSTANT) * 1.0e7;
+}
More information about the samba-cvs
mailing list