summaryrefslogtreecommitdiff
path: root/file.c
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-06-21 09:14:39 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-06-21 09:14:39 +0000
commitff97db81d1da421d5c11557da8815f178b1af5a4 (patch)
tree5b28d4ccd3e08ec93caf9d91e905fec15e20d1c5 /file.c
parenta847df14ca784a8bfd7d6daef936bdec58e9b2dc (diff)
merges r23670 from trunk into ruby_1_9_1.
-- * file.c (file_expand_path): associate the input encoding when copying an absolute path. [ruby-dev:38594] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_1@23783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'file.c')
-rw-r--r--file.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/file.c b/file.c
index 3d5c33bd75..4ea759fa37 100644
--- a/file.c
+++ b/file.c
@@ -2723,6 +2723,7 @@ file_expand_path(VALUE fname, VALUE dname, int abs_mode, VALUE result)
p = buf + (s - b);
BUFCHECK(bdiff >= buflen);
memset(buf, '/', p - buf);
+ rb_enc_copy(result, fname);
}
if (p > buf && p[-1] == '/')
--p;