From d03dc07b8d2bc701a5a9cdfc6928725b32aefd45 Mon Sep 17 00:00:00 2001 From: John Ralls Date: Sat, 7 Nov 2020 13:20:22 -0800 Subject: [PATCH] Remove redundant and incorrectly named constant. --- libgnucash/engine/gnc-timezone.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libgnucash/engine/gnc-timezone.cpp b/libgnucash/engine/gnc-timezone.cpp index 6c03481d42..33f0609ec5 100644 --- a/libgnucash/engine/gnc-timezone.cpp +++ b/libgnucash/engine/gnc-timezone.cpp @@ -460,14 +460,12 @@ namespace IANAParser //Add in the tzinfo indexes consumed in the previous loop start_index = info_index_zero + time_count; - //Can't use sizeof(TZInfo) because it's padded out to 8 bytes. - static const size_t tzinfo_size = 6; - auto abbrev = start_index + type_count * tzinfo_size; + auto abbrev = start_index + type_count * ttinfo_size; auto std_dist = abbrev + char_count; auto gmt_dist = std_dist + type_count; for(uint32_t index = 0; index < type_count; ++index) { - fb_index = start_index + index * tzinfo_size; + fb_index = start_index + index * ttinfo_size; /* Use memcpy instead of static_cast to avoid memory alignment issues with chars */ TTInfo info{}; memcpy(&info, &fileblock[fb_index], ttinfo_size);