summaryrefslogtreecommitdiff
path: root/zen/format_unit.cpp
diff options
context:
space:
mode:
authorB Stack <bgstack15@gmail.com>2021-03-03 01:18:05 +0000
committerB Stack <bgstack15@gmail.com>2021-03-03 01:18:05 +0000
commit320f1ae680d73da35a0cfe4846eb687d8616bcac (patch)
tree6fb17404841b30822a2d9204e3e0932e55f05ebb /zen/format_unit.cpp
parentMerge branch '11.6' into 'master' (diff)
parentadd upstream 11.7 (diff)
downloadFreeFileSync-320f1ae680d73da35a0cfe4846eb687d8616bcac.tar.gz
FreeFileSync-320f1ae680d73da35a0cfe4846eb687d8616bcac.tar.bz2
FreeFileSync-320f1ae680d73da35a0cfe4846eb687d8616bcac.zip
Merge branch '11.7' into 'master'11.7
add upstream 11.7 See merge request opensource-tracking/FreeFileSync!31
Diffstat (limited to 'zen/format_unit.cpp')
-rw-r--r--zen/format_unit.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/zen/format_unit.cpp b/zen/format_unit.cpp
index 28943de7..b2d1b59a 100644
--- a/zen/format_unit.cpp
+++ b/zen/format_unit.cpp
@@ -128,9 +128,9 @@ std::wstring roundToBlock(double timeInHigh,
std::wstring zen::formatRemainingTime(double timeInSec)
{
- const int steps10[] = { 1, 2, 5, 10 };
- const int steps24[] = { 1, 2, 3, 4, 6, 8, 12, 24 };
- const int steps60[] = { 1, 2, 5, 10, 15, 20, 30, 60 };
+ const int steps10[] = {1, 2, 5, 10};
+ const int steps24[] = {1, 2, 3, 4, 6, 8, 12, 24};
+ const int steps60[] = {1, 2, 5, 10, 15, 20, 30, 60};
//determine preferred unit
double timeInUnit = timeInSec;
@@ -178,7 +178,7 @@ std::wstring zen::formatUtcToLocalTime(time_t utcTime)
{
auto errorMsg = [&] { return _("Error") + L" (time_t: " + numberTo<std::wstring>(utcTime) + L')'; };
- TimeComp loc = getLocalTime(utcTime);
+ const TimeComp& loc = getLocalTime(utcTime);
std::wstring dateString = utfTo<std::wstring>(formatTime(Zstr("%x %X"), loc));
return !dateString.empty() ? dateString : errorMsg();
bgstack15