summaryrefslogtreecommitdiff
path: root/include/ruby
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-05-25 20:39:30 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-05-25 20:39:30 +0000
commit5a9f87f17912f863624bd475b9589e29d6b79056 (patch)
tree43e5a4808e291ba341ecab29e5dc48f06f2228b9 /include/ruby
parenta273dc9b1669f7659a894f3b46ae7fbbedfdb89c (diff)
* include/ruby/ruby.h (FilePathValue): prevent from GC.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23571 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include/ruby')
-rw-r--r--include/ruby/ruby.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h
index 54018ab277..7da0b9e908 100644
--- a/include/ruby/ruby.h
+++ b/include/ruby/ruby.h
@@ -417,7 +417,7 @@ VALUE rb_str_export(VALUE);
VALUE rb_str_export_locale(VALUE);
VALUE rb_get_path(VALUE);
-#define FilePathValue(v) ((v) = rb_get_path(v))
+#define FilePathValue(v) (RB_GC_GUARD(v) = rb_get_path(v))
VALUE rb_get_path_no_checksafe(VALUE);
#define FilePathStringValue(v) ((v) = rb_get_path_no_checksafe(v))