summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-18 19:51:14 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-18 19:51:14 +0000
commit664874ced67a84e18a21774ad00fec3c190daf96 (patch)
treeac186522b0131087afb20b31e1a5411c79b19102
parent5023492957351796cbde1db1d60c3a5ab5771ccf (diff)
* debug.c (set_debug_option): need the declaration.
* debug.c (set_debug_option): use the same macro with the implementation at win32/win32.c. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48485 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog7
-rw-r--r--debug.c5
2 files changed, 11 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 6acd84265b..3c6d863f7e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+Wed Nov 19 04:49:07 2014 NAKAMURA Usaku <usa@ruby-lang.org>
+
+ * debug.c (set_debug_option): need the declaration.
+
+ * debug.c (set_debug_option): use the same macro with the implementation
+ at win32/win32.c.
+
Wed Nov 19 04:16:24 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
* parse.y (symbol_list): fix the node type of literal symbol list
diff --git a/debug.c b/debug.c
index 4eaae0d978..a5ae6a7467 100644
--- a/debug.c
+++ b/debug.c
@@ -140,6 +140,9 @@ ruby_debug_breakpoint(void)
static void
set_debug_option(const char *str, int len, void *arg)
{
+#if defined _WIN32 && RUBY_MSVCRT_VERSION >= 80
+ extern int ruby_w32_rtc_error;
+#endif
#define SET_WHEN(name, var, val) do { \
if (len == sizeof(name) - 1 && \
strncmp(str, (name), len) == 0) { \
@@ -149,7 +152,7 @@ set_debug_option(const char *str, int len, void *arg)
} while (0)
SET_WHEN("gc_stress", *ruby_initial_gc_stress_ptr, Qtrue);
SET_WHEN("core", ruby_enable_coredump, 1);
-#if defined _WIN32 && defined _MSC_VER && _MSC_VER >= 1400
+#if defined _WIN32 && RUBY_MSVCRT_VERSION >= 80
SET_WHEN("rtc_error", ruby_w32_rtc_error, 1);
#endif
fprintf(stderr, "unexpected debug option: %.*s\n", len, str);