diff --git a/ext/date/date_parse.c b/ext/date/date_parse.c index 1214f39..d7d22fa 100644 --- a/ext/date/date_parse.c +++ b/ext/date/date_parse.c @@ -441,8 +441,10 @@ date_zone_to_diff(VALUE str) char *s, *p; VALUE sign; VALUE hour = Qnil, min = Qnil, sec = Qnil; + volatile VALUE str_orig; s = RSTRING_PTR(str); + str_orig = str; if (strncmp(s, "gmt", 3) == 0 || strncmp(s, "utc", 3) == 0)