From 4d4d1ad3b33514d0c1303c6efcceb7ede278e1c9 Mon Sep 17 00:00:00 2001 From: Nick Terrell Date: Tue, 6 Sep 2016 20:27:11 -0700 Subject: [PATCH] Fix minor potential narrowing bug --- contrib/pzstd/Pzstd.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/pzstd/Pzstd.cpp b/contrib/pzstd/Pzstd.cpp index 0caf0f93..87c4c202 100644 --- a/contrib/pzstd/Pzstd.cpp +++ b/contrib/pzstd/Pzstd.cpp @@ -221,7 +221,7 @@ static size_t calculateStep( std::uintmax_t size, size_t numThreads, const ZSTD_parameters ¶ms) { - size_t step = 1ul << (params.cParams.windowLog + 2); + size_t step = size_t{1} << (params.cParams.windowLog + 2); // If file size is known, see if a smaller step will spread work more evenly if (size != 0) { const std::uintmax_t newStep = size / std::uintmax_t{numThreads};