diff options
author | shugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-08-28 15:01:07 +0000 |
---|---|---|
committer | shugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-08-28 15:01:07 +0000 |
commit | 6a7481c38db51f1cd0818412375c76202ad04168 (patch) | |
tree | 3345eb2f9ffb0a84f78448829e85bc32baef8342 /strftime.c | |
parent | 5ef4c56784db4b4ac6eefc865774015a75796acf (diff) | |
download | ruby-6a7481c38db51f1cd0818412375c76202ad04168.tar.gz |
* strftime.c (rb_strftime): Time.mktime(2000).strftime("%-S") should
return "0", not "".
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'strftime.c')
-rw-r--r-- | strftime.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/strftime.c b/strftime.c index d90e8e5267..2b8033cf28 100644 --- a/strftime.c +++ b/strftime.c @@ -275,7 +275,7 @@ rb_strftime(char *s, size_t maxsize, const char *format, const struct tm *timept do { \ int l; \ if (precision <= 0) precision = (def_prec); \ - if (flags & BIT_OF(LEFT)) precision = 0; \ + if (flags & BIT_OF(LEFT)) precision = 1; \ l = snprintf(s, endp - s, \ ((!padding || padding == (def_pad)) ? "%.*"fmt : "%*"fmt), \ precision, val); \ |