From 35141f304e319109c322f797ae71c0b9420ccb05 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Thu, 5 Jan 2023 18:21:25 +0100 Subject: time: Set daylight to 1 for matching DST/offset change (bug 29951) The daylight variable is supposed to be set to 1 if DST is ever in use for the current time zone. But __tzfile_read used to do this: __daylight = rule_stdoff != rule_dstoff; This check can fail to set __daylight to 1 if the DST and non-DST offsets happen to be the same. --- timezone/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'timezone/Makefile') diff --git a/timezone/Makefile b/timezone/Makefile index a789c22..5002de3 100644 --- a/timezone/Makefile +++ b/timezone/Makefile @@ -23,7 +23,7 @@ subdir := timezone include ../Makeconfig others := zdump zic -tests := test-tz tst-timezone tst-tzset tst-bz28707 +tests := test-tz tst-timezone tst-tzset tst-bz28707 tst-bz29951 generated-dirs += testdata @@ -86,11 +86,13 @@ $(objpfx)tst-timezone.out: $(addprefix $(testdata)/, \ Europe/London) $(objpfx)tst-tzset.out: $(addprefix $(testdata)/XT, 1 2 3 4) $(objpfx)tst-bz28707.out: $(testdata)/XT5 +$(objpfx)tst-bz29951.out: $(testdata)/XT6 test-tz-ENV = TZDIR=$(testdata) tst-timezone-ENV = TZDIR=$(testdata) tst-tzset-ENV = TZDIR=$(testdata) tst-bz28707-ENV = TZDIR=$(testdata) +tst-bz29951-ENV = TZDIR=$(testdata) # Note this must come second in the deps list for $(built-program-cmd) to work. zic-deps = $(objpfx)zic $(leapseconds) yearistype -- cgit v1.1