diff options
author | jperkin <jperkin@pkgsrc.org> | 2022-03-03 16:23:31 +0000 |
---|---|---|
committer | jperkin <jperkin@pkgsrc.org> | 2022-03-03 16:23:31 +0000 |
commit | 0967eb68b5245576be667c0d8bacac40b1596713 (patch) | |
tree | 4cb6ed9a71f7480741c4fb8c029b0dbcc3ea388d /mail/rspamd | |
parent | 3fae09e5e92d20a3fdb9d26de507bd153d096c62 (diff) | |
download | pkgsrc-0967eb68b5245576be667c0d8bacac40b1596713.tar.gz |
rspamd: Explicitly use std::log10.
Diffstat (limited to 'mail/rspamd')
-rw-r--r-- | mail/rspamd/distinfo | 3 | ||||
-rw-r--r-- | mail/rspamd/patches/patch-contrib_doctest_doctest_doctest.h | 19 |
2 files changed, 21 insertions, 1 deletions
diff --git a/mail/rspamd/distinfo b/mail/rspamd/distinfo index 358cb2285e4..8aba12144d7 100644 --- a/mail/rspamd/distinfo +++ b/mail/rspamd/distinfo @@ -1,8 +1,9 @@ -$NetBSD: distinfo,v 1.40 2021/12/21 15:00:41 triaxx Exp $ +$NetBSD: distinfo,v 1.41 2022/03/03 16:23:31 jperkin Exp $ BLAKE2s (rspamd-3.1.tar.gz) = d23e3aba1974e31236295171e7d74df624497c9ab11c8d8ebfe95830b70d9d7a SHA512 (rspamd-3.1.tar.gz) = 3c3c06c10d3dfc90e4bc92c7ebaff4bd4854d3b0e56d6476f0223918c4a52f4cc7a8b381b1f867164199ee18ea00eda77ae0315925f3fd71596d610200667178 Size (rspamd-3.1.tar.gz) = 5566920 bytes SHA1 (patch-CMakeLists.txt) = e50137fb3c2d467a8c880491e5d34d475e1a8d05 SHA1 (patch-cmake_Toolset.cmake) = fbc4027fedb4261ce913701ebbb32d8395bc7783 +SHA1 (patch-contrib_doctest_doctest_doctest.h) = 5238cb9f837e1d8f402023ddc2f7d02dda3f67ab SHA1 (patch-contrib_fpconv_fpconv.c) = b1ec2b07570674458e69020ccbf25f0374d894f6 diff --git a/mail/rspamd/patches/patch-contrib_doctest_doctest_doctest.h b/mail/rspamd/patches/patch-contrib_doctest_doctest_doctest.h new file mode 100644 index 00000000000..7a767f4d5ec --- /dev/null +++ b/mail/rspamd/patches/patch-contrib_doctest_doctest_doctest.h @@ -0,0 +1,19 @@ +$NetBSD: patch-contrib_doctest_doctest_doctest.h,v 1.1 2022/03/03 16:23:31 jperkin Exp $ + +Explicitly use std::log10(). + +--- contrib/doctest/doctest/doctest.h.orig 2021-11-01 14:33:30.000000000 +0000 ++++ contrib/doctest/doctest/doctest.h +@@ -5803,9 +5803,9 @@ namespace { + separator_to_stream(); + s << std::dec; + +- auto totwidth = int(std::ceil(log10((std::max(p.numTestCasesPassingFilters, static_cast<unsigned>(p.numAsserts))) + 1))); +- auto passwidth = int(std::ceil(log10((std::max(p.numTestCasesPassingFilters - p.numTestCasesFailed, static_cast<unsigned>(p.numAsserts - p.numAssertsFailed))) + 1))); +- auto failwidth = int(std::ceil(log10((std::max(p.numTestCasesFailed, static_cast<unsigned>(p.numAssertsFailed))) + 1))); ++ auto totwidth = int(std::ceil(std::log10((std::max(p.numTestCasesPassingFilters, static_cast<unsigned>(p.numAsserts))) + 1))); ++ auto passwidth = int(std::ceil(std::log10((std::max(p.numTestCasesPassingFilters - p.numTestCasesFailed, static_cast<unsigned>(p.numAsserts - p.numAssertsFailed))) + 1))); ++ auto failwidth = int(std::ceil(std::log10((std::max(p.numTestCasesFailed, static_cast<unsigned>(p.numAssertsFailed))) + 1))); + const bool anythingFailed = p.numTestCasesFailed > 0 || p.numAssertsFailed > 0; + s << Color::Cyan << "[doctest] " << Color::None << "test cases: " << std::setw(totwidth) + << p.numTestCasesPassingFilters << " | " |