summary refs log tree commit diff stats
path: root/src/common/dcc.c
diff options
context:
space:
mode:
authorBerke Viktor <berkeviktor@aol.com>2011-12-11 17:34:02 +0100
committerBerke Viktor <berkeviktor@aol.com>2011-12-11 17:34:02 +0100
commit132ef6cb50201cb6ab8ab0609a88ccce62aa6a21 (patch)
tree0d47c10fa3b9789592c6513286d57a0c010b071f /src/common/dcc.c
parent2012320d0eed36e0461e44ac9be8cc162c135bf5 (diff)
initial patches for linux compatibility
Diffstat (limited to 'src/common/dcc.c')
-rw-r--r--src/common/dcc.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/common/dcc.c b/src/common/dcc.c
index 9375095e..d91b7e8e 100644
--- a/src/common/dcc.c
+++ b/src/common/dcc.c
@@ -40,6 +40,8 @@
 
 #ifdef WIN32
 #include <windows.h>
+#else
+#include <unistd.h>
 #endif
 
 #include "xchat.h"
@@ -56,7 +58,9 @@
 
 #ifdef USE_DCC64
 #define BIG_STR_TO_INT(x) strtoull(x,NULL,10)
+#ifdef WIN32
 #define stat _stat64
+#endif
 #else
 #define BIG_STR_TO_INT(x) strtoul(x,NULL,10)
 #endif
@@ -1983,7 +1987,9 @@ is_same_file (struct DCC *dcc, struct DCC *new_dcc)
 		return TRUE;
 
 	/* now handle case-insensitive Filesystems: HFS+, FAT */
-#ifndef WIN32
+#ifdef WIN32
+	/* warning no win32 implementation - behaviour may be unreliable */
+#else
 	/* this fstat() shouldn't really fail */
 	if ((dcc->fp == -1 ? stat (dcc->destfile_fs, &st_a) : fstat (dcc->fp, &st_a)) == -1)
 		return FALSE;