diff options
| author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-06-13 05:59:01 +0000 |
|---|---|---|
| committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-06-13 05:59:01 +0000 |
| commit | b28112bf672cb14aeaf99a2b3e69f537de9f5c93 (patch) | |
| tree | 2a781eb5bd6245b48d6abfcd26f157ac2a05e073 | |
| parent | 7d053825eeb27465bf7def0f81f43d57b5847d9f (diff) | |
| download | ruby-b28112bf672cb14aeaf99a2b3e69f537de9f5c93.tar.gz ruby-b28112bf672cb14aeaf99a2b3e69f537de9f5c93.tar.xz ruby-b28112bf672cb14aeaf99a2b3e69f537de9f5c93.zip | |
* load.c (rb_require_safe): FilePathValue() implies rb_str_new4().
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@23679 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 4 | ||||
| -rw-r--r-- | load.c | 3 |
2 files changed, 4 insertions, 3 deletions
@@ -1,4 +1,6 @@ -Sat Jun 13 14:57:36 2009 Nobuyoshi Nakada <nobu@ruby-lang.org> +Sat Jun 13 14:58:57 2009 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * load.c (rb_require_safe): FilePathValue() implies rb_str_new4(). * load.c (rb_mod_autoload): try conversion to path like as require. [ruby-core:23834] @@ -545,7 +545,7 @@ load_ext(VALUE path) VALUE rb_require_safe(VALUE fname, int safe) { - VALUE result = Qnil; + volatile VALUE result = Qnil; rb_thread_t *th = GET_THREAD(); volatile VALUE errinfo = th->errinfo; int state; @@ -563,7 +563,6 @@ rb_require_safe(VALUE fname, int safe) rb_set_safe_level_force(safe); FilePathValue(fname); - RB_GC_GUARD(fname) = rb_str_new4(fname); rb_set_safe_level_force(0); found = search_required(fname, &path); if (found) { |
