diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2015-10-14 02:51:05 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2015-10-15 06:49:23 +0000 |
commit | b4b7703e4335460cf48bfd6440f116359994c8ff (patch) | |
tree | 66b6ab43d6fb13d037160d7384d1a7a93d92940b /vcl/qa | |
parent | 90d82f73b89d8a0b0b13d224dbd1a741a10a7fd9 (diff) |
cppcheck:variableScope
Change-Id: I9b671637fbe0f32e695d22b74bfb40a39a9fe884
Reviewed-on: https://gerrit.libreoffice.org/19364
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'vcl/qa')
-rw-r--r-- | vcl/qa/cppunit/timer.cxx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/vcl/qa/cppunit/timer.cxx b/vcl/qa/cppunit/timer.cxx index 2e8ee3d0acc9..0bc86667f09d 100644 --- a/vcl/qa/cppunit/timer.cxx +++ b/vcl/qa/cppunit/timer.cxx @@ -209,7 +209,6 @@ void TimerTest::testAutoTimer() const double exp = (nDurationMs * nEventsCount); sal_Int32 nCount = 0; - double dur = 0; std::ostringstream msg; // Repeat when we have random latencies. @@ -224,7 +223,7 @@ void TimerTest::testAutoTimer() } const auto end = std::chrono::high_resolution_clock::now(); - dur = std::chrono::duration<double, std::milli>(end - start).count(); + double dur = std::chrono::duration<double, std::milli>(end - start).count(); msg << std::setprecision(2) << std::fixed << "periodic multi-timer - dur: " @@ -257,7 +256,6 @@ void TimerTest::testMultiAutoTimers() const double expX = (exp / nDurationMsX); const double expY = (exp / nDurationMsY); - double dur = 0; sal_Int32 nCountX = 0; sal_Int32 nCountY = 0; sal_Int32 nCount = 0; @@ -282,7 +280,7 @@ void TimerTest::testMultiAutoTimers() } const auto end = std::chrono::high_resolution_clock::now(); - dur = std::chrono::duration<double, std::milli>(end - start).count(); + double dur = std::chrono::duration<double, std::milli>(end - start).count(); msg << std::setprecision(2) << std::fixed << "periodic multi-timer - dur: " << dur << " (" << exp << ") ms, nCount: " << nCount |