diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-08-02 04:46:41 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-08-02 04:46:41 +0000 |
commit | 46e848a65a866663161edecc81d1b46aa3e36de3 (patch) | |
tree | 39edd93b75f3af6a3c8c5e59bbbd09794105a916 /sprintf.c | |
parent | 12b1e59f2eacd346da550bbc30cc3644909cb314 (diff) | |
download | ruby-46e848a65a866663161edecc81d1b46aa3e36de3.tar.gz |
* sprintf.c (rb_f_sprintf): should not check positional number as
width. [ruby-core:11838]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12861 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'sprintf.c')
-rw-r--r-- | sprintf.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -349,7 +349,6 @@ rb_str_format(int argc, const VALUE *argv, VALUE fmt) case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': - CHECK_FOR_WIDTH(flags); n = 0; GETNUM(n, width); if (*p == '$') { @@ -360,6 +359,7 @@ rb_str_format(int argc, const VALUE *argv, VALUE fmt) p++; goto retry; } + CHECK_FOR_WIDTH(flags); width = n; flags |= FWIDTH; goto retry; |