From c5bfbe0dc3086b39218a4d9a8ef2ce4f538673da Mon Sep 17 00:00:00 2001 From: Brad House Date: Wed, 19 Jun 2019 08:22:39 -0400 Subject: [PATCH] work around mingw compile failure --- test/ares-test.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/test/ares-test.h b/test/ares-test.h index 7d749bb1..a3d1d37c 100644 --- a/test/ares-test.h +++ b/test/ares-test.h @@ -349,7 +349,9 @@ class TempFile : public TransientFile { }; #ifdef _WIN32 -extern "C" static int setenv(const char *name, const char *value, int overwrite) +extern "C" { + +static int setenv(const char *name, const char *value, int overwrite) { char *buffer; size_t buf_size; @@ -372,11 +374,12 @@ extern "C" static int setenv(const char *name, const char *value, int overwrite) return 0; } -extern "C" static int unsetenv(const char *name) +static int unsetenv(const char *name) { return setenv(name, NULL, 1); } +} /* extern "C" */ #endif // RAII class for a temporary environment variable value.