On 2026-06-29 01:03, Liu Chao via tz wrote:
Do we need to consider the scenario where it is switched from the rearguard 
mode to the vanguard mode?

Yes, that's the idea.

I was working along the same idea as you, and installed the attached slightly-bigger patch; please give it a try.

By the way, what do you need rearguard for? Is this for Java, or something else?
From 49bb3e7273261f61caec2f0c13cecad89b6ce1f6 Mon Sep 17 00:00:00 2001
From: Paul Eggert <[email protected]>
Date: Mon, 29 Jun 2026 01:04:53 -0700
Subject: [PROPOSED] =?UTF-8?q?Fix=20previous=20patch=20for=20rearguard?=
 =?UTF-8?q?=E2=86=92vanguard?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

* ziguard.awk: Adjust previous patch again by using
$4 == 2026 instead of looking at stdoff or NF.
---
 ziguard.awk | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ziguard.awk b/ziguard.awk
index 79df9bef..ba3a1340 100644
--- a/ziguard.awk
+++ b/ziguard.awk
@@ -184,7 +184,7 @@ DATAFORM != "main" {
 	  dstoff = get_minutes(rules)
 	} else {
 	  # The DST offset is normally an hour, but there are special cases.
-	  if (rules == "Morocco" && stdoff == 60) {
+	  if (rules == "Morocco" && $4 == 2026) {
 	    dstoff = -60
 	  } else if (rules == "NBorneo") {
 	    dstoff = 20
@@ -286,7 +286,7 @@ DATAFORM != "main" {
 	}
       }
     }
-    if ($1 ~ /^[+0-9-]/ && stdoff == 60) {
+    if ($1 ~ /^[+0-9-]/ && $4 == 2026) {
       if (DATAFORM == "rearguard") {
 	sub(/1:00\tMorocco/, "0:00\tMorocco")
 	sub(/\t\+01\/\+00/, "\t+00/+01")
-- 
2.53.0

Reply via email to