aboutsummaryrefslogtreecommitdiff
path: root/src/bin/psql/common.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/psql/common.c')
-rw-r--r--src/bin/psql/common.c26
1 files changed, 1 insertions, 25 deletions
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c
index 2e30c4e9a26..76e0c0e6b89 100644
--- a/src/bin/psql/common.c
+++ b/src/bin/psql/common.c
@@ -3,7 +3,7 @@
*
* Copyright (c) 2000-2006, PostgreSQL Global Development Group
*
- * $PostgreSQL: pgsql/src/bin/psql/common.c,v 1.130 2006/10/04 00:30:05 momjian Exp $
+ * $PostgreSQL: pgsql/src/bin/psql/common.c,v 1.131 2006/12/16 00:38:43 adunstan Exp $
*/
#include "postgres_fe.h"
#include "common.h"
@@ -11,12 +11,10 @@
#include <ctype.h>
#include <signal.h>
#ifndef WIN32
-#include <sys/time.h>
#include <unistd.h> /* for write() */
#else
#include <io.h> /* for _write() */
#include <win32.h>
-#include <sys/timeb.h> /* for _ftime() */
#endif
#include "pqsignal.h"
@@ -28,28 +26,6 @@
#include "mbprint.h"
-/* Workarounds for Windows */
-/* Probably to be moved up the source tree in the future, perhaps to be replaced by
- * more specific checks like configure-style HAVE_GETTIMEOFDAY macros.
- */
-#ifndef WIN32
-
-typedef struct timeval TimevalStruct;
-
-#define GETTIMEOFDAY(T) gettimeofday(T, NULL)
-#define DIFF_MSEC(T, U) \
- ((((int) ((T)->tv_sec - (U)->tv_sec)) * 1000000.0 + \
- ((int) ((T)->tv_usec - (U)->tv_usec))) / 1000.0)
-#else
-
-typedef struct _timeb TimevalStruct;
-
-#define GETTIMEOFDAY(T) _ftime(T)
-#define DIFF_MSEC(T, U) \
- (((T)->time - (U)->time) * 1000.0 + \
- ((T)->millitm - (U)->millitm))
-#endif
-
static bool ExecQueryUsingCursor(const char *query, double *elapsed_msec);
static bool command_no_begin(const char *query);