aboutsummaryrefslogtreecommitdiffstats
path: root/vsnprintf.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-11-22 16:06:38 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-11-22 16:06:38 +0000
commit18c0fc890c4847eb19e1997b88c4f8e043321f9b (patch)
treeda50464c4b00789f4f1f7239a9aeaaee38517fcd /vsnprintf.c
parent94e6c0c233bd386e09e5700d947d4f5e4fca3914 (diff)
downloadruby-18c0fc890c4847eb19e1997b88c4f8e043321f9b.tar.gz
* vsnprintf.c (BSD_vfprintf): don't output floating point
when the precision is 0. [ruby-dev:42615] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vsnprintf.c')
-rw-r--r--vsnprintf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/vsnprintf.c b/vsnprintf.c
index 5f564c2abf..6778b90d8f 100644
--- a/vsnprintf.c
+++ b/vsnprintf.c
@@ -790,7 +790,7 @@ reswitch: switch (ch) {
#ifdef FLOATING_POINT
case 'a':
case 'A':
- if (prec >= 0) {
+ if (prec > 0) {
flags |= ALT;
prec++;
}