summaryrefslogtreecommitdiff
path: root/otherlibs/unix/gettimeofday.c
diff options
context:
space:
mode:
Diffstat (limited to 'otherlibs/unix/gettimeofday.c')
-rw-r--r--otherlibs/unix/gettimeofday.c37
1 files changed, 0 insertions, 37 deletions
diff --git a/otherlibs/unix/gettimeofday.c b/otherlibs/unix/gettimeofday.c
deleted file mode 100644
index 97f80f05ee..0000000000
--- a/otherlibs/unix/gettimeofday.c
+++ /dev/null
@@ -1,37 +0,0 @@
-/***********************************************************************/
-/* */
-/* Objective Caml */
-/* */
-/* Xavier Leroy, projet Cristal, INRIA Rocquencourt */
-/* */
-/* Copyright 1996 Institut National de Recherche en Informatique et */
-/* en Automatique. All rights reserved. This file is distributed */
-/* under the terms of the GNU Library General Public License, with */
-/* the special exception on linking described in file ../../LICENSE. */
-/* */
-/***********************************************************************/
-
-/* $Id$ */
-
-#include <mlvalues.h>
-#include <alloc.h>
-#include "unixsupport.h"
-
-#ifdef HAS_GETTIMEOFDAY
-
-#include <sys/types.h>
-#include <sys/time.h>
-
-CAMLprim value unix_gettimeofday(value unit)
-{
- struct timeval tp;
- if (gettimeofday(&tp, NULL) == -1) uerror("gettimeofday", Nothing);
- return copy_double((double) tp.tv_sec + (double) tp.tv_usec / 1e6);
-}
-
-#else
-
-CAMLprim value unix_gettimeofday(value unit)
-{ invalid_argument("gettimeofday not implemented"); }
-
-#endif