summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-08-05 14:19:26 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-08-05 14:19:26 +0000
commit549605c15dd30252fbdf777f719bd9572a5e3b92 (patch)
treec9d63cbd6788aec7a54e7bb8083611cd0ddfe190
parent743c279d7007e8e0aa5d7d715950b83458400bf4 (diff)
* hasn.c (env_str_new): taint the string. get rid of a test failure
introduced at r55811. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55818 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--hash.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index b09b87996b..83fcd536ac 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Fri Aug 5 23:18:35 2016 NAKAMURA Usaku <usa@ruby-lang.org>
+
+ * hasn.c (env_str_new): taint the string. get rid of a test failure
+ introduced at r55811.
+
Fri Aug 5 17:04:02 2016 Nobuyoshi Nakada <nobu@ruby-lang.org>
* hash.c (w32_getenv): call rb_w32_getenv and rb_w32_ugetenv via
diff --git a/hash.c b/hash.c
index 3af376255e..1474460ea3 100644
--- a/hash.c
+++ b/hash.c
@@ -2944,6 +2944,7 @@ env_str_new(const char *ptr, long len)
{
#ifdef _WIN32
VALUE str = env_str_transcode(rb_utf8_str_new(ptr, len), rb_locale_encoding());
+ OBJ_TAINT(str); /* rb_locale_str_new makes tainted string, but rb_utf8_str_new doesn't */
#else
VALUE str = rb_locale_str_new(ptr, len);
#endif