summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--file.c9
-rw-r--r--version.h2
3 files changed, 6 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index b34ed8c..1a9a544 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Sat Nov 10 01:25:52 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * file.c (append_fspath): no need to do encoding trick here.
+
Sat Nov 10 00:37:02 2012 NAKAMURA Usaku <usa@ruby-lang.org>
* siphash.h: check configure macros before include newer headers.
diff --git a/file.c b/file.c
index 386a8fb..c1db6d7 100644
--- a/file.c
+++ b/file.c
@@ -2874,14 +2874,7 @@ append_fspath(VALUE result, VALUE fname, char *dir, rb_encoding **enc, rb_encodi
VALUE dirname = Qnil;
size_t dirlen = strlen(dir), buflen = rb_str_capacity(result);
- if (*enc != fsenc) {
- rb_encoding *direnc = rb_enc_check(fname, dirname = rb_enc_str_new(dir, dirlen, fsenc));
- if (direnc != fsenc) {
- dirname = rb_str_conv_enc(dirname, fsenc, direnc);
- RSTRING_GETMEM(dirname, cwdp, dirlen);
- }
- *enc = direnc;
- }
+ *enc = fsenc;
do {buflen *= 2;} while (dirlen > buflen);
rb_str_resize(result, buflen);
buf = RSTRING_PTR(result);
diff --git a/version.h b/version.h
index e714b08..b2b42e1 100644
--- a/version.h
+++ b/version.h
@@ -1,5 +1,5 @@
#define RUBY_VERSION "1.9.3"
-#define RUBY_PATCHLEVEL 326
+#define RUBY_PATCHLEVEL 327
#define RUBY_RELEASE_DATE "2012-11-10"
#define RUBY_RELEASE_YEAR 2012