summaryrefslogtreecommitdiffstats
path: root/sprintf.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-01-18 15:37:22 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-01-18 15:37:22 +0000
commit65c68b606e40d75b0a6b5780b54d5b503b8ee810 (patch)
tree195f369ae27cb705f217aca04b2895e2ef18adff /sprintf.c
parent4bfb24fe8f79ab1ddf71e9ba271e80fa4e66e303 (diff)
downloadruby-65c68b606e40d75b0a6b5780b54d5b503b8ee810.tar.gz
ruby-65c68b606e40d75b0a6b5780b54d5b503b8ee810.tar.xz
ruby-65c68b606e40d75b0a6b5780b54d5b503b8ee810.zip
* sprintf.c (rb_str_format): set result encoding for wider width.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15117 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'sprintf.c')
-rw-r--r--sprintf.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sprintf.c b/sprintf.c
index 28f4ff90e..3b5d38afa 100644
--- a/sprintf.c
+++ b/sprintf.c
@@ -490,6 +490,7 @@ rb_str_format(int argc, const VALUE *argv, VALUE fmt)
buf[blen++] = ' ';
}
}
+ rb_enc_associate(result, enc);
break;
}
}