From 29ce58298f6c6f4df1a1081cca30a8f32c74279e Mon Sep 17 00:00:00 2001 From: tb Date: Sun, 20 Jun 2021 14:09:59 +0000 Subject: [PATCH] Add a test case for fmt_scaled.c r1.20 --- regress/lib/libutil/fmt_scaled/fmt_test.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/regress/lib/libutil/fmt_scaled/fmt_test.c b/regress/lib/libutil/fmt_scaled/fmt_test.c index fd9d1c81bfb..f35c4451407 100644 --- a/regress/lib/libutil/fmt_scaled/fmt_test.c +++ b/regress/lib/libutil/fmt_scaled/fmt_test.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fmt_test.c,v 1.16 2020/02/14 19:17:34 schwarze Exp $ */ +/* $OpenBSD: fmt_test.c,v 1.17 2021/06/20 14:09:59 tb Exp $ */ /* * Combined tests for fmt_scaled and scan_scaled. @@ -169,6 +169,8 @@ struct { /* the test cases */ { "-2K", -2048LL, 0 }, /* negatives */ { "-2.2K", -2252LL, 0 }, /* neg with fract */ { "4.5k", 4608, 0 }, + { "3.333755555555t", 3665502936412, 0 }, + { "-3.333755555555t", -3665502936412, 0 }, { "4.5555555555555555K", 4664, 0 }, { "4.5555555555555555555K", 4664, 0 }, /* handle enough digits? */ { "4.555555555555555555555555555555K", 4664, 0 }, /* ignores extra digits? */ -- 2.20.1