|
PostgreSQL Source Code git master
|
#include "postgres_fe.h"#include <fcntl.h>#include <sys/stat.h>#include <time.h>#include "pg_getopt.h"#include "private.h"#include "tzfile.h"
Go to the source code of this file.
Data Structures | |
| struct | rule |
| struct | zone |
| struct | link |
| struct | lookup |
| struct | attype |
| struct | timerange |
Typedefs | |
| typedef int_fast64_t | zic_t |
| typedef intmax_t | lineno_t |
Enumerations | |
| enum | { PERCENT_Z_LEN_BOUND = sizeof "+995959" - 1 } |
| enum | { WORK_AROUND_QTBUG_53071 = true } |
| #define LDAYSPERWEEK ((zic_t) DAYSPERWEEK) |
| #define linkat | ( | targetdir, | |
| target, | |||
| linknamedir, | |||
| linkname, | |||
| flag | |||
| ) | (itssymlink(target) ? (errno = ENOTSUP, -1) : link(target, linkname)) |
| #define PRIdZIC PRIdFAST64 |
| #define SCNdZIC SCNdFAST64 |
| #define ZIC_MAX INT_FAST64_MAX |
| #define ZIC_MIN INT_FAST64_MIN |
Definition at line 2589 of file zic.c.
References _, buf, error(), fb(), MINSPERHOUR, SECSPERMIN, and sign.
Referenced by doabbr().
Definition at line 3351 of file zic.c.
References attype::at, attypes, attype::dontmerge, growalloc(), timecnt, timecnt_alloc, type, and attype::type.
Referenced by outzone().
Definition at line 3361 of file zic.c.
References _, charcnt, chars, desigidx, error(), EXIT_FAILURE, fb(), i, isdsts, j, newabbr(), ttisstds, ttisuts, typecnt, TZ_MAX_TYPES, utoffs, and want_bloat().
Referenced by outzone(), and writezone().
Definition at line 3428 of file zic.c.
References _, comment_leapexpires, corr, error(), EXIT_FAILURE, fb(), hi_time, i, leapcnt, leapexpires, oadd(), SECSPERDAY, tadd(), trans, and warning().
Referenced by main().
Definition at line 433 of file zic.c.
References _, fb(), and memory_exhausted().
Referenced by writezone().
Definition at line 1186 of file zic.c.
References _, eat(), error(), errors, EXIT_FAILURE, fb(), getsave(), i, j, nrules, nzones, qsort, rule::r_filename, rule::r_linenum, rule::r_name, rcomp(), rules, warning(), zone::z_rules, and zones.
Referenced by main().
Definition at line 3656 of file zic.c.
References _, ciequal(), ciprefix(), fb(), itsabbr(), lasts, noise, table, warning(), wday_names, and word().
Referenced by getleapdatetime(), infile(), inleap(), and rulesub().
|
static |
Definition at line 885 of file zic.c.
References _, error(), fb(), len, name, noise, and warning().
Referenced by namecheck().
Definition at line 1994 of file zic.c.
References b, buf, i, and val.
Referenced by ExecInitExprRec(), fmtfloat(), fmtint(), fmtptr(), get_rule_expr(), pg_strfromd(), print_double(), print_double(), print_double(), print_double(), puttzcode(), and writezone().
|
static |
Definition at line 2633 of file zic.c.
References abbroffset(), fb(), format, is_alpha(), len, memcpy(), PERCENT_Z_LEN_BOUND, and sprintf.
Referenced by outzone(), and stringzone().
Definition at line 1032 of file zic.c.
References _, close_file(), directory, ENOTSUP, EXIT_FAILURE, fb(), fprintf, free, hardlinkerr(), itsdir(), itssymlink(), mkdirs(), progname, relname, strerror, symlink, and warning().
Referenced by main().
Definition at line 452 of file zic.c.
References malloc, and memcheck().
Referenced by getfields(), itsdir(), outzone(), relname(), and writezone().
Definition at line 458 of file zic.c.
References memcheck(), and realloc.
Referenced by growalloc().
Definition at line 3722 of file zic.c.
References _, emalloc(), error(), EXIT_FAILURE, fb(), is_space(), and size_product().
Referenced by infile().
Definition at line 1380 of file zic.c.
References _, error(), fb(), HOURSPERDAY, MINSPERHOUR, noise, oadd(), pg_fallthrough, SCNdZIC, SECSPERHOUR, SECSPERMIN, sign, warning(), and ZIC_MAX.
Referenced by getleapdatetime(), getsave(), inzsub(), and rulesub().
Definition at line 1677 of file zic.c.
References _, byword(), EPOCH_YEAR, error(), fb(), gethms(), i, isleap, j, leapmaxyear, leapminyear, leapseen, len_months, len_years, LP_DAY, LP_MONTH, LP_TIME, LP_YEAR, max_time, min_time, mon_names, oadd(), SCNdZIC, SECSPERDAY, tadd(), and TM_JANUARY.
Referenced by inexpires(), and inleap().
|
static |
Definition at line 470 of file zic.c.
References _, erealloc(), fb(), memory_exhausted(), nitems, PTRDIFF_MAX, size_product(), and WORK_AROUND_QTBUG_53071.
Definition at line 1796 of file zic.c.
References _, error(), EXPIRES_FIELDS, getleapdatetime(), and leapexpires.
Referenced by infile().
Definition at line 1271 of file zic.c.
References _, buf, byword(), close_file(), comment_leapexpires, eat(), error(), EXIT_FAILURE, fb(), filename, fprintf, free, getfields(), inexpires(), inleap(), inlink(), inrule(), inzcont(), inzone(), LC_EXPIRES, LC_LEAP, LC_LINK, LC_RULE, LC_ZONE, leap_line_codes, leapsec, name, progname, SCNdZIC, strerror, and zi_line_codes.
Referenced by AlterSystemSetConfigFile(), isolation_start_test(), main(), psql_start_test(), and readfile().
Definition at line 1764 of file zic.c.
References _, byword(), error(), fb(), getleapdatetime(), LEAP_FIELDS, leap_types, leapadd(), LP_CORR, and LP_ROLL.
Referenced by infile().
Definition at line 1807 of file zic.c.
References _, ecpyalloc(), error(), filename, growalloc(), link::l_filename, link::l_linenum, link::l_linkname, link::l_target, LF_LINKNAME, LF_TARGET, linenum, LINK_FIELDS, links, namecheck(), nlinks, and nlinks_alloc.
Referenced by infile().
Definition at line 1482 of file zic.c.
References _, ecpyalloc(), error(), fb(), filename, getsave(), growalloc(), linenum, max_abbrvar_len, nrules, nrules_alloc, rule::r_abbrvar, rule::r_filename, rule::r_isdst, rule::r_linenum, rule::r_name, rule::r_save, RF_ABBRVAR, RF_COMMAND, RF_DAY, RF_HIYEAR, RF_LOYEAR, RF_MONTH, RF_NAME, RF_SAVE, RF_TOD, RULE_FIELDS, rules, and rulesub().
Referenced by infile().
Definition at line 1529 of file zic.c.
References _, error(), fb(), i, inzsub(), lcltime, nzones, psxrules, tzdefault, TZDEFRULES, ZF_NAME, ZONE_MAXFIELDS, and zones.
Referenced by infile().
Definition at line 1578 of file zic.c.
References _, ecpyalloc(), error(), fb(), filename, gethms(), growalloc(), linenum, max_format_len, max_time, min_time, namecheck(), noise, nzones, nzones_alloc, rule::r_filename, rule::r_linenum, rule::r_loyear, rpytime(), rulesub(), warning(), zone::z_filename, zone::z_format, zone::z_format_specifier, zone::z_linenum, zone::z_name, zone::z_rule, zone::z_stdoff, zone::z_untilrule, zone::z_untiltime, ZF_FORMAT, ZF_NAME, ZF_RULE, ZF_STDOFF, ZF_TILDAY, ZF_TILMONTH, ZF_TILTIME, ZF_TILYEAR, ZFC_FORMAT, ZFC_RULE, ZFC_STDOFF, ZFC_TILDAY, ZFC_TILMONTH, ZFC_TILTIME, ZFC_TILYEAR, and zones.
Definition at line 3489 of file zic.c.
References a.
Definition at line 3471 of file zic.c.
References a.
Referenced by getfields().
|
static |
Definition at line 2057 of file zic.c.
References timerange::defaulttype, trans, types, and ZIC_MAX.
Referenced by writezone().
Definition at line 18 of file win32link.c.
References _dosmaperr(), and fb().
Definition at line 3556 of file zic.c.
References a.
Referenced by ciequal(), ciprefix(), itsabbr(), and rulesub().
Definition at line 680 of file zic.c.
References _, adjleap(), associate(), bloat, change_directory(), close_file(), directory, dolink(), eat(), error(), errors, EXIT_FAILURE, EXIT_SUCCESS, fb(), fprintf, getopt(), i, infile(), j, lcltime, leapsec, links, nlinks, noise, nzones, optarg, optind, outzone(), print_abbrevs, print_cutoff, printf, progname, psxrules, S_IWGRP, S_IWOTH, timerange_option(), TYPE_BIT, TZDEFAULT, tzdefault, TZDEFRULES, usage(), warning(), warnings, zone::z_name, ZIC_BLOAT_DEFAULT, and zones.
Definition at line 444 of file zic.c.
References fb(), memory_exhausted(), and strerror.
Referenced by ecpyalloc(), emalloc(), and erealloc().
Definition at line 418 of file zic.c.
References _, EXIT_FAILURE, fb(), fprintf, and progname.
Referenced by align_to(), growalloc(), memcheck(), and size_product().
Definition at line 3955 of file zic.c.
References _, ecpyalloc(), err(), error(), EXIT_FAILURE, fb(), free, itsdir(), mkdir, MKDIR_UMASK, name, progname, and strerror.
Referenced by change_directory(), dolink(), and writezone().
Definition at line 929 of file zic.c.
References _, componentcheck(), fb(), name, noise, and warning().
Definition at line 3915 of file zic.c.
References _, charcnt, chars, error(), EXIT_FAILURE, fb(), GRANDPARENTED, i, is_alpha(), noise, TZ_MAX_CHARS, warning(), and ZIC_MAX_ABBR_LEN_WO_WARN.
Referenced by addtype().
Definition at line 3769 of file zic.c.
References fb(), time_overflow(), ZIC_MAX, and ZIC_MIN.
Referenced by adjleap(), gethms(), getleapdatetime(), outzone(), and rpytime().
Definition at line 2949 of file zic.c.
References _, addtt(), addtype(), attype::at, attypes, charcnt, compat, DC_DOM, doabbr(), attype::dontmerge, eat(), eats(), emalloc(), EPOCH_YEAR, error(), fb(), free, i, INITIALIZE, j, leapmaxyear, leapminyear, leapseen, max_abbrvar_len, max_format_len, max_time, max_year, min_time, min_year, noise, oadd(), rule::r_isdst, rpytime(), stringzone(), tadd(), timecnt, TM_JANUARY, type, typecnt, updateminmax(), want_bloat(), warning(), writezone(), YEARSPERREPEAT, ZIC_MAX, ZIC_MIN, ZIC_VERSION, and ZIC_VERSION_PRE_2013.
Referenced by main().
Definition at line 2016 of file zic.c.
References buf, convert(), fb(), and val.
Referenced by puttzcodepass(), and writezone().
Definition at line 2025 of file zic.c.
References buf, convert64(), fb(), puttzcode(), and val.
Referenced by writezone().
Definition at line 3806 of file zic.c.
References _, DC_DOWGEQ, DC_DOWLEQ, EPOCH_WDAY, EPOCH_YEAR, error(), EXIT_FAILURE, fb(), i, isleap, LDAYSPERWEEK, len_months, len_years, max_time, min_time, noise, oadd(), SECSPERDAY, SECSPERREPEAT, tadd(), TM_FEBRUARY, TM_JANUARY, warning(), y, YEARSPERREPEAT, ZIC_MAX, and ZIC_MIN.
|
static |
Definition at line 1832 of file zic.c.
References _, begin_years, byword(), DC_DOM, DC_DOWGEQ, DC_DOWLEQ, ecpyalloc(), end_years, error(), EXIT_FAILURE, fb(), fprintf, free, gethms(), lasts, len_months, lowerit(), mon_names, progname, SCNdZIC, wday_names, YR_MAXIMUM, YR_MINIMUM, YR_ONLY, ZIC_MAX, and ZIC_MIN.
Definition at line 425 of file zic.c.
References _, fb(), memory_exhausted(), and nitems.
Referenced by getfields(), growalloc(), and writezone().
Definition at line 2685 of file zic.c.
References DAYSPERWEEK, fb(), HOURSPERDAY, len, MINSPERHOUR, result, SECSPERMIN, and sprintf.
Referenced by stringrule(), and stringzone().
Definition at line 2719 of file zic.c.
References compat, DAYSPERWEEK, DC_DOM, DC_DOWGEQ, DC_DOWLEQ, fb(), len_months, MINSPERHOUR, result, SECSPERDAY, SECSPERMIN, sprintf, stringoffset(), and TM_FEBRUARY.
Referenced by stringzone().
Definition at line 2814 of file zic.c.
References compat, DC_DOM, doabbr(), fb(), hi_time, i, len, max_time, MINSPERHOUR, rule::r_month, result, rule_cmp(), SECSPERDAY, SECSPERMIN, stringoffset(), stringrule(), TM_DECEMBER, TM_JANUARY, and ZIC_MAX.
Referenced by outzone().
Definition at line 3777 of file zic.c.
References fb(), max_time, min_time, and time_overflow().
Referenced by adjleap(), getleapdatetime(), outzone(), rpytime(), and writezone().
Definition at line 626 of file zic.c.
References fb(), hi_time, lo_time, max_time, and min_time.
Referenced by main().
Definition at line 561 of file zic.c.
References _, close_file(), EXIT_SUCCESS, fb(), fprintf, and progname.
Definition at line 533 of file zic.c.
References _, fb(), fprintf, verror(), and warnings.
Referenced by adjleap(), associate(), byword(), componentcheck(), dolink(), get_role_password(), gethms(), inzsub(), main(), md5_crypt_verify(), namecheck(), newabbr(), outzone(), rpytime(), and writezone().
|
static |
Definition at line 2084 of file zic.c.
References _, _Alignof, addtype(), align_to(), attype::at, atcomp(), attypes, chars, close_file(), convert(), corr, timerange::defaulttype, desigidx, directory, DO, emalloc(), error(), EXIT_FAILURE, fb(), fprintf, free, hi_time, i, isdsts, j, leapcnt, limitrange(), lo_time, max_time, memcpy(), min_time, mkdirs(), name, noise, print_abbrevs, print_cutoff, progname, puttzcode(), puttzcodepass(), qsort, roll, size_product(), strerror, tadd(), timecnt, tm, trans, ttisstds, ttisuts, type, attype::type, typecnt, types, TZ_MAGIC, TZ_MAX_CHARS, TZ_MAX_TIMES, TZ_MAX_TYPES, tzhead::tzh_charcnt, tzhead::tzh_leapcnt, tzhead::tzh_magic, tzhead::tzh_timecnt, tzhead::tzh_ttisstdcnt, tzhead::tzh_ttisutcnt, tzhead::tzh_typecnt, tzhead::tzh_version, utoffs, want_bloat(), warning(), WORK_AROUND_QTBUG_53071, and ZIC_MAX.
Referenced by outzone().
|
static |
Referenced by addtt(), outzone(), and writezone().
|
static |
Definition at line 667 of file zic.c.
Referenced by main(), and want_bloat().
|
static |
Definition at line 182 of file zic.c.
Referenced by addtype(), newabbr(), outzone(), pg_interpret_timezone_abbrev(), pg_timezone_abbrev_is_known(), tzloadbody(), and tzparse().
|
static |
Definition at line 408 of file zic.c.
Referenced by addtype(), getColorInfo(), initPopulateTable(), newabbr(), pg_reg_getcharacters(), and writezone().
|
static |
|
static |
Definition at line 410 of file zic.c.
Referenced by adjleap(), import_pg_statistic(), leapadd(), timesub(), tzloadbody(), and writezone().
|
static |
Definition at line 405 of file zic.c.
Referenced by addtype(), init_ttinfo(), tzloadbody(), and writezone().
Definition at line 658 of file zic.c.
Referenced by create_manifest_writer(), CreateBackupStreamer(), dolink(), GetConfFilesInDir(), identify_target_directory(), main(), open_file_in_directory(), PathNameCreateTemporaryDir(), relname(), search_directory(), verify_directory(), and writezone().
|
static |
Definition at line 183 of file zic.c.
Referenced by associate(), error(), and main().
|
static |
Definition at line 613 of file zic.c.
Referenced by adjleap(), stringzone(), timerange_option(), and writezone().
|
static |
Definition at line 404 of file zic.c.
Referenced by addtype(), and writezone().
|
static |
Definition at line 186 of file zic.c.
Referenced by adjleap(), leapadd(), tzloadbody(), and writezone().
|
static |
Definition at line 616 of file zic.c.
Referenced by adjleap(), and inexpires().
|
static |
Definition at line 189 of file zic.c.
Referenced by getleapdatetime(), and outzone().
|
static |
Definition at line 188 of file zic.c.
Referenced by getleapdatetime(), and outzone().
|
static |
Definition at line 187 of file zic.c.
Referenced by getleapdatetime(), and outzone().
|
static |
Definition at line 388 of file zic.c.
Referenced by getleapdatetime(), rpytime(), rulesub(), and stringrule().
Definition at line 393 of file zic.c.
Referenced by getleapdatetime(), and rpytime().
|
static |
|
static |
Definition at line 612 of file zic.c.
Referenced by timerange_option(), and writezone().
|
static |
|
static |
|
static |
Definition at line 606 of file zic.c.
Referenced by getleapdatetime(), inzsub(), outzone(), rpytime(), stringzone(), tadd(), timerange_option(), and writezone().
|
static |
Definition at line 193 of file zic.c.
Referenced by outzone(), and updateminmax().
|
static |
Definition at line 605 of file zic.c.
Referenced by getleapdatetime(), inzsub(), outzone(), rpytime(), tadd(), timerange_option(), and writezone().
|
static |
Definition at line 194 of file zic.c.
Referenced by outzone(), and updateminmax().
Definition at line 331 of file zic.c.
Referenced by getleapdatetime(), and rulesub().
|
static |
Definition at line 195 of file zic.c.
Referenced by byword(), componentcheck(), gethms(), inzsub(), main(), namecheck(), newabbr(), outzone(), rpytime(), and writezone().
|
static |
Definition at line 291 of file zic.c.
Referenced by associate(), and inrule().
|
static |
|
static |
Definition at line 196 of file zic.c.
Referenced by main(), and writezone().
|
static |
Definition at line 197 of file zic.c.
Referenced by main(), and writezone().
Definition at line 200 of file zic.c.
Referenced by change_directory(), close_file(), dolink(), infile(), main(), memory_exhausted(), mkdirs(), rulesub(), usage(), and writezone().
Definition at line 49 of file zic.c.
Referenced by growalloc().
|
static |
Definition at line 411 of file zic.c.
Referenced by leapadd(), and writezone().
|
static |
Definition at line 290 of file zic.c.
Referenced by associate(), fireRIRrules(), inrule(), and RelationBuildRuleLock().
|
static |
Definition at line 201 of file zic.c.
Referenced by addtt(), outzone(), tzloadbody(), tzparse(), and writezone().
|
static |
Definition at line 409 of file zic.c.
Referenced by add_tabstat_xact_level(), adjleap(), AtEOSubXact_PgStat_Relations(), AtEOXact_PgStat_Relations(), AtPrepare_PgStat_Relations(), find_tabstat_entry(), leapadd(), limitrange(), pgstat_report_analyze(), PostPrepare_PgStat_Relations(), restore_truncdrop_counters(), save_truncdrop_counters(), sqlnotice(), and writezone().
|
static |
Definition at line 406 of file zic.c.
Referenced by addtype(), and writezone().
|
static |
Definition at line 407 of file zic.c.
Referenced by addtype(), and writezone().
|
static |
Definition at line 203 of file zic.c.
Referenced by addtype(), outzone(), tzloadbody(), and writezone().
|
static |
Definition at line 403 of file zic.c.
Referenced by addtype(), and writezone().