summaryrefslogtreecommitdiff
path: root/storage/connect/tabfmt.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'storage/connect/tabfmt.cpp')
-rw-r--r--storage/connect/tabfmt.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/storage/connect/tabfmt.cpp b/storage/connect/tabfmt.cpp
index d5f8dc50a89..015f8d93b15 100644
--- a/storage/connect/tabfmt.cpp
+++ b/storage/connect/tabfmt.cpp
@@ -5,7 +5,7 @@
/* */
/* COPYRIGHT: */
/* ---------- */
-/* (C) Copyright to the author Olivier BERTRAND 2001 - 2014 */
+/* (C) Copyright to the author Olivier BERTRAND 2001 - 2015 */
/* */
/* WHAT THIS PROGRAM DOES: */
/* ----------------------- */
@@ -20,7 +20,7 @@
/***********************************************************************/
#include "my_global.h"
-#if defined(WIN32)
+#if defined(__WIN__)
#include <io.h>
#include <fcntl.h>
#include <errno.h>
@@ -102,14 +102,14 @@ PQRYRES CSVColumns(PGLOBAL g, char *dp, const char *fn, char sep,
} // endif info
// num_max = atoi(p+1); // Max num of record to test
-#if defined(WIN32)
+#if defined(__WIN__)
if (sep == ',' || strnicmp(setlocale(LC_NUMERIC, NULL), "French", 6))
dechar = '.';
else
dechar = ',';
-#else // !WIN32
+#else // !__WIN__
dechar = '.';
-#endif // !WIN32
+#endif // !__WIN__
if (trace)
htrc("File %s sep=%c q=%c hdr=%d mxr=%d\n",
@@ -147,7 +147,7 @@ PQRYRES CSVColumns(PGLOBAL g, char *dp, const char *fn, char sep,
if (fgets(buf, sizeof(buf), infile)) {
n = strlen(buf) + 1;
buf[n - 2] = '\0';
-#if defined(UNIX)
+#if !defined(__WIN__)
// The file can be imported from Windows
if (buf[n - 3] == '\r')
buf[n - 3] = 0;
@@ -204,7 +204,7 @@ PQRYRES CSVColumns(PGLOBAL g, char *dp, const char *fn, char sep,
if (fgets(buf, sizeof(buf), infile)) {
n = strlen(buf);
buf[n - 1] = '\0';
-#if defined(UNIX)
+#if !defined(__WIN__)
// The file can be imported from Windows
if (buf[n - 2] == '\r')
buf[n - 2] = 0;
@@ -625,7 +625,7 @@ bool TDBCSV::CheckErr(void)
/***********************************************************************/
/* CSV EstimatedLength. Returns an estimated minimum line length. */
/***********************************************************************/
-int TDBCSV::EstimatedLength(PGLOBAL g)
+int TDBCSV::EstimatedLength(void)
{
int n = 0;
PCOLDEF cdp;
@@ -1118,7 +1118,7 @@ PCOL TDBFMT::MakeCol(PGLOBAL g, PCOLDEF cdp, PCOL cprec, int n)
/* FMT EstimatedLength. Returns an estimated minimum line length. */
/* The big problem here is how can we astimated that minimum ? */
/***********************************************************************/
-int TDBFMT::EstimatedLength(PGLOBAL g)
+int TDBFMT::EstimatedLength(void)
{
// This is rather stupid !!!
return ((PDOSDEF)To_Def)->GetEnding() + (int)((Lrecl / 10) + 1);