* checktab.awk: Now that tzselect uses both country and continent as criteria for region list building, checktab needs to do the same when testing zone tabs for comment (field 4) requirements. Signed-off-by: J William Piggott <elseifthen@gmx.com> --- checktab.awk | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/checktab.awk b/checktab.awk index 6c2e41b..bbf7ce9 100644 --- a/checktab.awk +++ b/checktab.awk @@ -62,6 +62,7 @@ BEGIN { cc = cca[1] coordinates = $2 tz = $3 + continent = substr($3, 1, index($3, "/") - 1) comments = $4 if (cc < cc0) { printf "%s:%d: country code '%s' is out of order\n", \ @@ -76,8 +77,10 @@ BEGIN { cc = cca[i] cctz = cc tz cctztab[cctz] = 1 + ccct = cc continent if (cc2name[cc]) { cc_used[cc]++ + ccct_used[ccct]++ } else { printf "%s:%d: %s: unknown country code\n", \ zone_table, zone_NR, cc >>"/dev/stderr" @@ -95,7 +98,9 @@ BEGIN { for (cctz in cctztab) { cc = substr (cctz, 1, 2) tz = substr (cctz, 3) - if (1 < cc_used[cc]) { + continent = substr(tz, 1, index(tz, "/") - 1) + ccct = cc continent + if (1 < ccct_used[ccct]) { comments_needed[tz] = cc } }