summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-05-10 17:10:46 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-05-10 17:10:46 +0000
commit4aa34546074ee4d8cfdb35b092de93c1c4910d19 (patch)
tree15c6fe4c535e334f2e5788986cd81c591debb3c4
parente08f245464fe13fec4162b6d4852e31a7535d656 (diff)
* string.c (tr_trans): should not turn on modify flag if no
modification happens. [ruby-dev:34631] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16349 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog3
-rw-r--r--string.c1
2 files changed, 3 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index bc7d096752..11df1e0b59 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -6,6 +6,9 @@ Sat May 10 22:14:03 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
* string.c (tr_trans): should check src size, not str size.
[ruby-dev:34637]
+ * string.c (tr_trans): should not turn on modify flag if no
+ modification happens. [ruby-dev:34631]
+
Sat May 10 18:11:18 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
* string.c (rb_str_each_line): zero length record separator should
diff --git a/string.c b/string.c
index 1de91ff525..f21baed251 100644
--- a/string.c
+++ b/string.c
@@ -4331,7 +4331,6 @@ tr_trans(VALUE str, VALUE src, VALUE repl, int sflag)
}
else {
save = -1;
- modify = 1;
c = c0;
}
while (t - buf + tlen >= max) {