summaryrefslogtreecommitdiffstats
path: root/dir.c
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-06-10 09:15:55 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-06-10 09:15:55 +0000
commit74ec8a777bf91f3c5994c196aa4e58f507ace5f2 (patch)
treebe5ea151f5a7d303789b69acb40b008da9835e8f /dir.c
parentf1dad558a2455bf44cbb73c3f09e1601fc350515 (diff)
downloadruby-74ec8a777bf91f3c5994c196aa4e58f507ace5f2.tar.gz
ruby-74ec8a777bf91f3c5994c196aa4e58f507ace5f2.tar.xz
ruby-74ec8a777bf91f3c5994c196aa4e58f507ace5f2.zip
* dir.c (dir_s_getwd): directory path's encoding should be filesystem's
one. * lib/tmpdir.rb: ditto (but not finished yet.) git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@23661 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'dir.c')
-rw-r--r--dir.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/dir.c b/dir.c
index 5c7d00222..980b57a28 100644
--- a/dir.c
+++ b/dir.c
@@ -816,6 +816,7 @@ dir_s_getwd(VALUE dir)
rb_secure(4);
path = my_getcwd();
cwd = rb_tainted_str_new2(path);
+ rb_enc_associate(cwd, rb_filesystem_encoding());
xfree(path);
return cwd;