git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: 6c1c9f8) | patch
Simplify gettimeofday() fallback logic.
Sat, 6 Aug 2022 15:34:56 +0000 (08:34 -0700)
Sat, 6 Aug 2022 15:34:56 +0000 (08:34 -0700)
commit 922a8fa098404cbd5c6089e78eca4aebd828f847
Simplify gettimeofday() fallback logic.

There's no known supported system needing 1 argument gettimeofday()
support. The test for it was added a long time ago (92c6bf9775b). Remove.

Until now we tested whether a gettimeofday() fallback is needed when
targetting windows. Which lead to the odd result that HAVE_GETTIMEOFDAY only
being defined when targetting MinGW (which has gettimeofday() since at least
2007). As the fallback is specific to msvc, remove the configure code and
rename src/port/gettimeofday.c to src/port/win32gettimeofday.c.

While at it, also remove the definition of struct timezone, a forward
declaration of the struct is sufficient.

Reviewed-By: Tom Lane <tgl@sss.pgh.pa.us>
Reviewed-By: Thomas Munro <thomas.munro@gmail.com>
Discussion: https://postgr.es/m/20220806000311.ywx65iuchvj4qn2k@awork3.anarazel.de
config/c-library.m4 diff | blob | blame | history
configure diff | blob | blame | history
configure.ac diff | blob | blame | history
src/include/pg_config.h.in diff | blob | blame | history
src/include/port.h diff | blob | blame | history
src/include/port/win32_port.h diff | blob | blame | history
src/port/win32gettimeofday.c [moved from src/port/gettimeofday.c with 98% similarity] diff | blob | blame | history
src/tools/msvc/Mkvcbuild.pm diff | blob | blame | history
src/tools/msvc/Solution.pm diff | blob | blame | history
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /