Project

General

Profile

Bug #11744

zone_sun.tab file must remain sorted

Added by Andy Fiddaman about 1 year ago. Updated about 1 year ago.

Status:
Closed
Priority:
Urgent
Assignee:
Category:
system data
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:

Description

Following 11676, libzoneinfo cannot properly parse the zone_sun.tab file as it expects it to be sorted.


Related issues

Related to illumos gate - Bug #11676: Update tzdata to 2019cClosed

Actions
Related to OpenIndiana Distribution - Bug #11738: text-install fails with "IndexError: Index (0) out of range (0-0)" when selecting Europe in "Time Zone: Regions" screenNew

Actions

History

#1

Updated by Andy Fiddaman about 1 year ago

  • Related to Bug #11676: Update tzdata to 2019c added
#2

Updated by Andy Fiddaman about 1 year ago

  • Related to Bug #11738: text-install fails with "IndexError: Index (0) out of range (0-0)" when selecting Europe in "Time Zone: Regions" screen added
#3

Updated by Andy Fiddaman about 1 year ago

Review at: https://illumos.org/rb/r/2346/

Using this small test program (based on one provided by Alexander Pyhalov)

#include <libzoneinfo.h>
#include <locale.h>
#include <stdio.h>

int main()
{
        struct tz_continent *ctnts = NULL;
        struct tz_continent *pctnt = NULL;
        struct tz_country *cntries;
        int nctnt, nctry, i;

        setlocale(LC_MESSAGES, "");
        nctnt = get_tz_continents(&ctnts);

        if (nctnt == -1) {
                printf("No continent data\n");
                return(0);
        }

        for (i = 1, pctnt = ctnts; pctnt != NULL;
            pctnt = pctnt->ctnt_next, i++) {
                nctry = get_tz_countries(&cntries, pctnt);
                printf("%s  - %d\n", pctnt->ctnt_name, nctry);
        }

        return 0;
}

Before - note the -1 for Europe

Africa  - 51
America  - 53
Antarctica  - 2
Arctic  - 1
Asia  - 50
Atlantic  - 9
Australia  - 1
Europe  - -1
Indian  - 11
Pacific  - 28

After:

Africa  - 51
America  - 53
Antarctica  - 2
Arctic  - 1
Asia  - 50
Atlantic  - 9
Australia  - 1
Europe  - 49
Indian  - 11
Pacific  - 28
#4

Updated by Electric Monk about 1 year ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

git commit 4cfdb4666c89a959e76ef077c99ae7fb542dcf71

commit  4cfdb4666c89a959e76ef077c99ae7fb542dcf71
Author: Andy Fiddaman <omnios@citrus-it.co.uk>
Date:   2019-09-23T17:06:31.000Z

    11744 zone_sun.tab file must remain sorted
    Reviewed by: Jim Klimov <jim@cos.ru>
    Reviewed by: Marcel Telka <marcel@telka.sk>
    Reviewed by: Alexander Pyhalov <apyhalov@gmail.com>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF