summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debug.c5
-rw-r--r--localeinit.c2
2 files changed, 5 insertions, 2 deletions
diff --git a/debug.c b/debug.c
index b289969952..65d86870d2 100644
--- a/debug.c
+++ b/debug.c
@@ -110,6 +110,9 @@ ruby_debug_breakpoint(void)
# if RUBY_MSVCRT_VERSION >= 80
extern int ruby_w32_rtc_error;
# endif
+#endif
+#if defined _WIN32 || defined __CYGWIN__
+#include <windows.h>
UINT ruby_w32_codepage;
#endif
@@ -135,6 +138,8 @@ set_debug_option(const char *str, int len, void *arg)
# if RUBY_MSVCRT_VERSION >= 80
SET_WHEN("rtc_error", ruby_w32_rtc_error, 1);
# endif
+#endif
+#if defined _WIN32 || defined __CYGWIN__
{
int ov;
size_t retlen;
diff --git a/localeinit.c b/localeinit.c
index 1e1fd4fb29..544402b534 100644
--- a/localeinit.c
+++ b/localeinit.c
@@ -21,9 +21,7 @@
#if defined _WIN32 || defined __CYGWIN__
#define SIZEOF_CP_NAME ((sizeof(UINT) * 8 / 3) + 4)
#define CP_FORMAT(buf, codepage) snprintf(buf, sizeof(buf), "CP%u", (codepage))
-#endif
-#if defined _WIN32
extern UINT ruby_w32_codepage;
#endif