mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-25 10:03:03 +01:00
bdcc683d4e
Signed-off-by: Dave Woodfall <dave@slackbuilds.org> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
24 lines
817 B
Diff
24 lines
817 B
Diff
From b49a7575ebbe127e8bd344900a52c14b5d69dd7b Mon Sep 17 00:00:00 2001
|
|
From: Howard Hinnant <howard.hinnant@gmail.com>
|
|
Date: Tue, 18 May 2021 16:15:31 -0400
|
|
Subject: [PATCH] Zero initialize local_info in get_info
|
|
|
|
* Even when the result is unique, the second sys_info
|
|
should be zero initialized.
|
|
---
|
|
src/tz.cpp | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/src/tz.cpp b/src/tz.cpp
|
|
index 26babbd9..1592bc8f 100644
|
|
--- a/src/tz.cpp
|
|
+++ b/src/tz.cpp
|
|
@@ -2164,7 +2164,7 @@ time_zone::get_info_impl(local_seconds tp) const
|
|
{
|
|
using namespace std::chrono;
|
|
init();
|
|
- local_info i;
|
|
+ local_info i{};
|
|
i.result = local_info::unique;
|
|
auto tr = upper_bound(transitions_.begin(), transitions_.end(), tp,
|
|
[](const local_seconds& x, const transition& t)
|