summaryrefslogtreecommitdiff
path: root/ext/-test-
diff options
context:
space:
mode:
Diffstat (limited to 'ext/-test-')
-rw-r--r--ext/-test-/printf/printf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/-test-/printf/printf.c b/ext/-test-/printf/printf.c
index 53aad85..fd60b0f 100644
--- a/ext/-test-/printf/printf.c
+++ b/ext/-test-/printf/printf.c
@@ -79,7 +79,7 @@ printf_test_call(int argc, VALUE *argv, VALUE self)
if (!NIL_P(v = rb_hash_aref(opt, ID2SYM(rb_intern("prec"))))) {
*p++ = '.';
if (FIXNUM_P(v))
- p = utoa(p, p + sizeof(format), NUM2UINT(v));
+ p = utoa(p, format + sizeof(format), NUM2UINT(v));
}
}
*p++ = cnv;