Changeset: 0676a8142475 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0676a8142475 Modified Files: common/stream/stream.c gdk/gdk_logger.c tools/embedded/windows/monetdb_config.h.in Branch: embedded Log Message:
file_fgetpos and file_fsetpos now work correctly for large files when using mingw diffs (45 lines): diff --git a/common/stream/stream.c b/common/stream/stream.c --- a/common/stream/stream.c +++ b/common/stream/stream.c @@ -829,7 +829,7 @@ file_fgetpos(stream *s, lng *p) if (fp == NULL || p == NULL) return -1; -#if defined(NATIVE_WIN32) && _MSC_VER >= 1400 /* Visual Studio 2005 */ +#if defined(NATIVE_WIN32) && (_MSC_VER >= 1400 || defined(__MINGW32__)) /* Visual Studio 2005 */ *p = (lng) _ftelli64(fp); /* returns __int64 */ #else #ifdef HAVE_FSEEKO @@ -849,7 +849,7 @@ file_fsetpos(stream *s, lng p) if (fp == NULL) return -1; -#if defined(NATIVE_WIN32) && _MSC_VER >= 1400 /* Visual Studio 2005 */ +#if defined(NATIVE_WIN32) && (_MSC_VER >= 1400 || defined(__MINGW32__)) /* Visual Studio 2005 */ res = _fseeki64(fp, (__int64) p, SEEK_SET); #else #ifdef HAVE_FSEEKO diff --git a/gdk/gdk_logger.c b/gdk/gdk_logger.c --- a/gdk/gdk_logger.c +++ b/gdk/gdk_logger.c @@ -2577,6 +2577,7 @@ log_tend(logger *lg) l.flag = LOG_END; l.tid = lg->tid; l.nr = lg->tid; + if (res != GDK_SUCCEED || log_write_format(lg, &l) == LOG_ERR || mnstr_flush(lg->log) || diff --git a/tools/embedded/windows/monetdb_config.h.in b/tools/embedded/windows/monetdb_config.h.in --- a/tools/embedded/windows/monetdb_config.h.in +++ b/tools/embedded/windows/monetdb_config.h.in @@ -18,9 +18,6 @@ * _MSC_VER = 1800: Visual Studio 12.0 * _MSC_VER = 1900: Visual Studio 14.0 */ - -// FIXME! -#define STREAM_DEBUG 1 #ifndef _SEEN_MONETDB_CONFIG_H #define _SEEN_MONETDB_CONFIG_H 1 _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list