From 9dee6b1dced7c05c1b9e291cad06f646a7397d42 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Fri, 2 Nov 2012 13:48:29 -0400 Subject: Compile (with warnings) with mingw64 Patch from yayooo for bug 7260, forward-ported to 0.2.4. --- src/common/compat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/common/compat.c') diff --git a/src/common/compat.c b/src/common/compat.c index b8674a2f5f..74585cd614 100644 --- a/src/common/compat.c +++ b/src/common/compat.c @@ -425,7 +425,7 @@ tor_vasprintf(char **strp, const char *fmt, va_list args) else *strp = strp_tmp; return r; -#elif defined(_MSC_VER) +#elif defined(HAVE__VSCPRINTF) /* On Windows, _vsnprintf won't tell us the length of the string if it * overflows, so we need to use _vcsprintf to tell how much to allocate */ int len, r; -- cgit v1.2.3-54-g00ecf From 5e096b677097a24a2ab72385cd9b87b148fd5b62 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Fri, 2 Nov 2012 14:03:32 -0400 Subject: Remove an unused variable; part of mingw64 patch from yayooo --- src/common/compat.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src/common/compat.c') diff --git a/src/common/compat.c b/src/common/compat.c index 74585cd614..2a4763c0fc 100644 --- a/src/common/compat.c +++ b/src/common/compat.c @@ -429,7 +429,6 @@ tor_vasprintf(char **strp, const char *fmt, va_list args) /* On Windows, _vsnprintf won't tell us the length of the string if it * overflows, so we need to use _vcsprintf to tell how much to allocate */ int len, r; - char *res; len = _vscprintf(fmt, args); if (len < 0) { *strp = NULL; -- cgit v1.2.3-54-g00ecf