From 7c80c19e1dffb4421f91913bc79b9cb7596634a4 Mon Sep 17 00:00:00 2001 From: Vicent Marti Date: Wed, 23 Mar 2011 01:58:18 +0200 Subject: [PATCH] Fix compilation in MinGW --- include/git2/types.h | 2 +- src/fileops.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/git2/types.h b/include/git2/types.h index db09f3842..88f6b7d55 100644 --- a/include/git2/types.h +++ b/include/git2/types.h @@ -57,7 +57,7 @@ typedef __time64_t git_time_t; #elif defined(__MINGW32__) typedef off64_t git_off_t; -typedef time64_t git_time_t; +typedef __time64_t git_time_t; #else /* POSIX */ diff --git a/src/fileops.c b/src/fileops.c index e440ea6ab..d754c49ee 100644 --- a/src/fileops.c +++ b/src/fileops.c @@ -32,7 +32,7 @@ static int creat_tempfile(char *path_out, const char *tmp_dir, const char *filen git__joinpath(path_out, tmp_dir, filename); strcat(path_out, "_git2_XXXXXX"); -#ifdef GIT_WIN32 +#if defined(_MSC_VER) /* FIXME: there may be race conditions when multi-threading * with the library */ if (_mktemp_s(path_out, GIT_PATH_MAX) != 0)