]> granicus.if.org Git - postgresql/commitdiff
Make the order of the header file includes consistent in non-backend modules.
authorAmit Kapila <akapila@postgresql.org>
Wed, 23 Oct 2019 04:08:53 +0000 (09:38 +0530)
committerAmit Kapila <akapila@postgresql.org>
Fri, 25 Oct 2019 02:11:52 +0000 (07:41 +0530)
Similar to commit 7e735035f2, this commit makes the order of header file
inclusion consistent for non-backend modules.

In passing, fix the case where we were using angle brackets (<>) for the
local module includes instead of quotes ("").

Author: Vignesh C
Reviewed-by: Amit Kapila
Discussion: https://postgr.es/m/CALDaNm2Sznv8RR6Ex-iJO6xAdsxgWhCoETkaYX=+9DW3q0QCfA@mail.gmail.com

102 files changed:
src/bin/pg_archivecleanup/pg_archivecleanup.c
src/bin/pg_basebackup/pg_basebackup.c
src/bin/pg_basebackup/pg_receivewal.c
src/bin/pg_basebackup/pg_recvlogical.c
src/bin/pg_basebackup/receivelog.c
src/bin/pg_basebackup/streamutil.c
src/bin/pg_basebackup/walmethods.c
src/bin/pg_config/pg_config.c
src/bin/pg_controldata/pg_controldata.c
src/bin/pg_dump/common.c
src/bin/pg_dump/parallel.c
src/bin/pg_dump/pg_backup_archiver.c
src/bin/pg_dump/pg_backup_custom.c
src/bin/pg_dump/pg_backup_db.c
src/bin/pg_dump/pg_backup_directory.c
src/bin/pg_dump/pg_backup_null.c
src/bin/pg_dump/pg_backup_tar.c
src/bin/pg_dump/pg_dump.c
src/bin/pg_dump/pg_dump_sort.c
src/bin/pg_dump/pg_dumpall.c
src/bin/pg_dump/pg_restore.c
src/bin/pg_resetwal/pg_resetwal.c
src/bin/pg_rewind/datapagemap.c
src/bin/pg_rewind/fetch.c
src/bin/pg_rewind/filemap.c
src/bin/pg_rewind/libpq_fetch.c
src/bin/pg_rewind/parsexlog.c
src/bin/pg_rewind/pg_rewind.c
src/bin/pg_rewind/timeline.c
src/bin/pg_test_fsync/pg_test_fsync.c
src/bin/pg_upgrade/check.c
src/bin/pg_upgrade/controldata.c
src/bin/pg_upgrade/dump.c
src/bin/pg_upgrade/file.c
src/bin/pg_upgrade/function.c
src/bin/pg_upgrade/info.c
src/bin/pg_upgrade/option.c
src/bin/pg_upgrade/parallel.c
src/bin/pg_upgrade/pg_upgrade.c
src/bin/pg_upgrade/relfilenode.c
src/bin/pg_upgrade/server.c
src/bin/pg_upgrade/util.c
src/bin/pg_upgrade/version.c
src/bin/pg_waldump/compat.c
src/bin/pg_waldump/pg_waldump.c
src/bin/pgbench/pgbench.c
src/bin/psql/common.c
src/bin/psql/copy.c
src/bin/psql/crosstabview.c
src/bin/psql/describe.c
src/bin/psql/help.c
src/bin/psql/input.c
src/bin/psql/large_obj.c
src/bin/psql/mainloop.c
src/bin/psql/prompt.c
src/bin/psql/startup.c
src/bin/psql/variables.c
src/common/f2s.c
src/fe_utils/print.c
src/fe_utils/recovery_gen.c
src/fe_utils/string_utils.c
src/interfaces/ecpg/compatlib/informix.c
src/interfaces/ecpg/ecpglib/connect.c
src/interfaces/ecpg/ecpglib/data.c
src/interfaces/ecpg/ecpglib/descriptor.c
src/interfaces/ecpg/ecpglib/error.c
src/interfaces/ecpg/ecpglib/execute.c
src/interfaces/ecpg/ecpglib/memory.c
src/interfaces/ecpg/ecpglib/misc.c
src/interfaces/ecpg/ecpglib/prepare.c
src/interfaces/ecpg/ecpglib/sqlda.c
src/interfaces/ecpg/ecpglib/typename.c
src/interfaces/ecpg/pgtypeslib/common.c
src/interfaces/ecpg/pgtypeslib/datetime.c
src/interfaces/ecpg/pgtypeslib/dt_common.c
src/interfaces/ecpg/pgtypeslib/interval.c
src/interfaces/ecpg/pgtypeslib/numeric.c
src/interfaces/ecpg/pgtypeslib/timestamp.c
src/interfaces/ecpg/preproc/c_keywords.c
src/interfaces/ecpg/preproc/ecpg_keywords.c
src/interfaces/libpq/fe-auth.c
src/interfaces/libpq/fe-connect.c
src/interfaces/libpq/fe-exec.c
src/interfaces/libpq/fe-misc.c
src/interfaces/libpq/fe-protocol2.c
src/interfaces/libpq/fe-protocol3.c
src/interfaces/libpq/fe-secure-gssapi.c
src/interfaces/libpq/fe-secure.c
src/pl/plpgsql/src/pl_comp.c
src/pl/plpgsql/src/pl_exec.c
src/pl/plpgsql/src/pl_funcs.c
src/pl/plpgsql/src/pl_handler.c
src/port/pg_crc32c_armv8.c
src/port/pg_crc32c_sse42.c
src/port/tar.c
src/test/isolation/isolationtester.c
src/test/modules/test_ginpostinglist/test_ginpostinglist.c
src/test/modules/test_integerset/test_integerset.c
src/test/modules/test_rls_hooks/test_rls_hooks.c
src/test/modules/test_shm_mq/setup.c
src/test/regress/pg_regress.c
src/test/regress/regress.c

index bb4257ff188f2dbdb4fd01cb3f68f7e5d9801e1e..2917d7fc6396ed4e040cbbb4be005a2ce40dd890 100644 (file)
 #include <signal.h>
 #include <sys/time.h>
 
-#include "pg_getopt.h"
-
-#include "common/logging.h"
-
 #include "access/xlog_internal.h"
+#include "common/logging.h"
+#include "pg_getopt.h"
 
 const char *progname;
 
index 55ef13926da67620d5e1aa6844921e33297bf5ce..a9d162a7da2dc47627a1e70b47be437829349846 100644 (file)
@@ -35,9 +35,9 @@
 #include "fe_utils/string_utils.h"
 #include "getopt_long.h"
 #include "libpq-fe.h"
-#include "pqexpbuffer.h"
 #include "pgtar.h"
 #include "pgtime.h"
+#include "pqexpbuffer.h"
 #include "receivelog.h"
 #include "replication/basebackup.h"
 #include "streamutil.h"
index f39c1339d722c58fd374c37859ddb5d3ade712af..c0c8747982b8c91827219cf1896d0c9450803513 100644 (file)
 #include <sys/stat.h>
 #include <unistd.h>
 
+#include "access/xlog_internal.h"
 #include "common/file_perm.h"
 #include "common/logging.h"
-#include "libpq-fe.h"
-#include "access/xlog_internal.h"
 #include "getopt_long.h"
-
+#include "libpq-fe.h"
 #include "receivelog.h"
 #include "streamutil.h"
 
-
 /* Time to sleep between reconnection attempts */
 #define RECONNECT_SLEEP_TIME 5
 
index af29dd7651a4cefecb2c2225d43d456b0659ceb8..12a3505226401af6556cc339ffbdbce5b1b595b3 100644 (file)
 #include <sys/select.h>
 #endif
 
-/* local includes */
-#include "streamutil.h"
-
 #include "access/xlog_internal.h"
-#include "common/file_perm.h"
 #include "common/fe_memutils.h"
+#include "common/file_perm.h"
 #include "common/logging.h"
 #include "getopt_long.h"
 #include "libpq-fe.h"
 #include "libpq/pqsignal.h"
 #include "pqexpbuffer.h"
-
+#include "streamutil.h"
 
 /* Time to sleep between reconnection attempts */
 #define RECONNECT_SLEEP_TIME 5
index d73f6145c1a5e4841cf571ecdd015a0d72c11cf3..82fd9afe194c5d698a46573ce3cdc132f482297f 100644 (file)
 #include <sys/select.h>
 #endif
 
-/* local includes */
-#include "receivelog.h"
-#include "streamutil.h"
-
-#include "libpq-fe.h"
 #include "access/xlog_internal.h"
 #include "common/file_utils.h"
 #include "common/logging.h"
-
+#include "libpq-fe.h"
+#include "receivelog.h"
+#include "streamutil.h"
 
 /* fd and filename for currently open WAL file */
 static Walfile *walfile = NULL;
index 8d8ac11b664129395205b37b171895c1aea16d8b..94d1a12b9b701368fadde0d22081d9494b72001f 100644 (file)
 #include <sys/time.h>
 #include <unistd.h>
 
-/* local includes */
-#include "receivelog.h"
-#include "streamutil.h"
-
 #include "access/xlog_internal.h"
 #include "common/fe_memutils.h"
 #include "common/file_perm.h"
@@ -29,6 +25,8 @@
 #include "fe_utils/connect.h"
 #include "port/pg_bswap.h"
 #include "pqexpbuffer.h"
+#include "receivelog.h"
+#include "streamutil.h"
 
 #define ERRCODE_DUPLICATE_OBJECT  "42710"
 
index 8ec12e6f723c32507751da0ca019fafcac849bce..d4d15b3e061427c8f7340ec383d980ff44b9b9c7 100644 (file)
 #include <zlib.h>
 #endif
 
-#include "pgtar.h"
 #include "common/file_perm.h"
 #include "common/file_utils.h"
-
+#include "pgtar.h"
 #include "receivelog.h"
 #include "streamutil.h"
 
index 5279e7fd797d7867643dd9ae31e79d0cf653e641..a1da918aedd3fb97656101d4c7cc400f8cf3d4c4 100644 (file)
@@ -24,8 +24,8 @@
 
 #include "postgres_fe.h"
 
-#include "port.h"
 #include "common/config_info.h"
+#include "port.h"
 
 static const char *progname;
 
index ff17804723e5220e39d6dcd2216dd709dc00aebb..b14767f8b608e4147f4e6311668d9d8a4f225914 100644 (file)
@@ -26,9 +26,8 @@
 #include "catalog/pg_control.h"
 #include "common/controldata_utils.h"
 #include "common/logging.h"
-#include "pg_getopt.h"
 #include "getopt_long.h"
-
+#include "pg_getopt.h"
 
 static void
 usage(const char *progname)
index 3549f7bc082857ca41e47fd639d0b1b329736c68..37432a6f4bbfd53062e6940d232f7e2e3e5fe4a0 100644 (file)
  */
 #include "postgres_fe.h"
 
-#include "pg_backup_archiver.h"
-#include "pg_backup_utils.h"
-#include "pg_dump.h"
-
 #include <ctype.h>
 
 #include "catalog/pg_class_d.h"
 #include "fe_utils/string_utils.h"
-
+#include "pg_backup_archiver.h"
+#include "pg_backup_utils.h"
+#include "pg_dump.h"
 
 /*
  * Variables for mapping DumpId to DumpableObject
index 03479f1a13cc5558784f33bdef86333d37269a0d..24239fa5eaefed1560b7c83f34eebbc6f1dcda39 100644 (file)
 #include <sys/select.h>
 #endif
 
+#include "fe_utils/string_utils.h"
 #include "parallel.h"
 #include "pg_backup_utils.h"
-
-#include "fe_utils/string_utils.h"
 #include "port/pg_bswap.h"
 
 /* Mnemonic macros for indexing the fd array returned by pipe(2) */
index 6c739ce6633c5dafdb54c26e2f5dda0d62eb9f5c..d051f267baad4bf0ed398d844a35b9761a512b67 100644 (file)
 #include <io.h>
 #endif
 
+#include "dumputils.h"
+#include "fe_utils/string_utils.h"
+#include "libpq/libpq-fs.h"
 #include "parallel.h"
 #include "pg_backup_archiver.h"
 #include "pg_backup_db.h"
 #include "pg_backup_utils.h"
-#include "dumputils.h"
-#include "fe_utils/string_utils.h"
-
-#include "libpq/libpq-fs.h"
 
 #define TEXT_DUMP_HEADER "--\n-- PostgreSQL database dump\n--\n\n"
 #define TEXT_DUMPALL_HEADER "--\n-- PostgreSQL database cluster dump\n--\n\n"
index 497b81b6840b3048d8940116adea4f68c635751b..fc742f5b560404e20ff2cb6527a4b6e6ba6ea95f 100644 (file)
  */
 #include "postgres_fe.h"
 
+#include "common/file_utils.h"
 #include "compress_io.h"
 #include "parallel.h"
 #include "pg_backup_utils.h"
-#include "common/file_utils.h"
-
 
 /*--------
  * Routines in the format interface
index ee822c524972e78be13e45b2b5760d206ff443f9..6dba7e19e433da869ac074798d4a0c66c418a090 100644 (file)
  */
 #include "postgres_fe.h"
 
-#include "fe_utils/connect.h"
-#include "fe_utils/string_utils.h"
-
-#include "dumputils.h"
-#include "parallel.h"
-#include "pg_backup_archiver.h"
-#include "pg_backup_db.h"
-#include "pg_backup_utils.h"
-
 #include <unistd.h>
 #include <ctype.h>
 #ifdef HAVE_TERMIOS_H
 #include <termios.h>
 #endif
 
+#include "dumputils.h"
+#include "fe_utils/connect.h"
+#include "fe_utils/string_utils.h"
+#include "parallel.h"
+#include "pg_backup_archiver.h"
+#include "pg_backup_db.h"
+#include "pg_backup_utils.h"
 
 static void _check_database_version(ArchiveHandle *AH);
 static PGconn *_connectDB(ArchiveHandle *AH, const char *newdbname, const char *newUser);
index e1afecfa6e0bc5bb31b230f590e949745fe754ce..aa00bcaaff235ef223e4a0692de81e8df71a6b60 100644 (file)
  */
 #include "postgres_fe.h"
 
+#include <dirent.h>
+#include <sys/stat.h>
+
+#include "common/file_utils.h"
 #include "compress_io.h"
 #include "parallel.h"
 #include "pg_backup_utils.h"
-#include "common/file_utils.h"
-
-#include <dirent.h>
-#include <sys/stat.h>
 
 typedef struct
 {
index 32c911a365f164f915e95d270a2c1bcff2a3aa55..c62f9436aaa7af56f9788355e98810cd709f41e9 100644 (file)
  */
 #include "postgres_fe.h"
 
-#include "pg_backup_archiver.h"
-#include "pg_backup_utils.h"
 #include "fe_utils/string_utils.h"
-
 #include "libpq/libpq-fs.h"
+#include "pg_backup_archiver.h"
+#include "pg_backup_utils.h"
 
 static void _WriteData(ArchiveHandle *AH, const void *data, size_t dLen);
 static void _WriteBlobData(ArchiveHandle *AH, const void *data, size_t dLen);
index dead8fc580345315c2586e2fa93ccfc4f555293e..fd74835165b5a97cb04a90e683c7bb2381cfd7cd 100644 (file)
  */
 #include "postgres_fe.h"
 
-#include "pg_backup_archiver.h"
-#include "pg_backup_tar.h"
-#include "pg_backup_utils.h"
-#include "pgtar.h"
-#include "common/file_utils.h"
-#include "fe_utils/string_utils.h"
-
 #include <sys/stat.h>
 #include <ctype.h>
 #include <limits.h>
 #include <unistd.h>
 
+#include "common/file_utils.h"
+#include "fe_utils/string_utils.h"
+#include "pg_backup_archiver.h"
+#include "pg_backup_tar.h"
+#include "pg_backup_utils.h"
+#include "pgtar.h"
+
 static void _ArchiveEntry(ArchiveHandle *AH, TocEntry *te);
 static void _StartData(ArchiveHandle *AH, TocEntry *te);
 static void _WriteData(ArchiveHandle *AH, const void *data, size_t dLen);
index 2a087d7a1cac717048ef067ffe9fb210aa0a7cd7..bf69adc2f4de6226b6bbc129a73705e42af2b568 100644 (file)
@@ -38,8 +38,6 @@
 #include <termios.h>
 #endif
 
-#include "getopt_long.h"
-
 #include "access/attnum.h"
 #include "access/sysattr.h"
 #include "access/transam.h"
 #include "catalog/pg_proc_d.h"
 #include "catalog/pg_trigger_d.h"
 #include "catalog/pg_type_d.h"
-#include "libpq/libpq-fs.h"
-#include "storage/block.h"
-
 #include "dumputils.h"
+#include "fe_utils/connect.h"
+#include "fe_utils/string_utils.h"
+#include "getopt_long.h"
+#include "libpq/libpq-fs.h"
 #include "parallel.h"
 #include "pg_backup_db.h"
 #include "pg_backup_utils.h"
 #include "pg_dump.h"
-#include "fe_utils/connect.h"
-#include "fe_utils/string_utils.h"
-
+#include "storage/block.h"
 
 typedef struct
 {
index 31fc06a2557802609749c379aefc517eae62a55b..ad0131648aa20401e427234ddb1e29afd05fbbba 100644 (file)
  */
 #include "postgres_fe.h"
 
+#include "catalog/pg_class_d.h"
 #include "pg_backup_archiver.h"
 #include "pg_backup_utils.h"
 #include "pg_dump.h"
 
-#include "catalog/pg_class_d.h"
-
 /*
  * Sort priority for database object types.
  * Objects are sorted by type, and within a type by name.
index 0981efcf5d671b1724e938881afeebfdf49bf74c..1442ea9a4061688574fc4b327fcb6322d0422671 100644 (file)
 #include <time.h>
 #include <unistd.h>
 
-#include "getopt_long.h"
-
-#include "dumputils.h"
-#include "pg_backup.h"
 #include "common/file_utils.h"
 #include "common/logging.h"
+#include "dumputils.h"
 #include "fe_utils/connect.h"
 #include "fe_utils/string_utils.h"
+#include "getopt_long.h"
+#include "pg_backup.h"
 
 /* version string we expect back from pg_dump */
 #define PGDUMP_VERSIONSTR "pg_dump (PostgreSQL) " PG_VERSION "\n"
index 40a6b3745cb4c66831fe2fb1e0cc1a320cf57d1b..d1a36b1495fe4b70bf4044f2ac9ca674c72e1b09 100644 (file)
 #include <termios.h>
 #endif
 
-#include "getopt_long.h"
-
 #include "dumputils.h"
+#include "getopt_long.h"
 #include "parallel.h"
 #include "pg_backup_utils.h"
 
-
 static void usage(const char *progname);
 
 int
index f85ea2db52f780b4ab72c546e0c57130e42b4690..c83f865246c6b547cfb657946d9a454a0f24ab3e 100644 (file)
@@ -44,9 +44,9 @@
 #include <time.h>
 #include <unistd.h>
 
-#include "access/transam.h"
 #include "access/heaptoast.h"
 #include "access/multixact.h"
+#include "access/transam.h"
 #include "access/xlog.h"
 #include "access/xlog_internal.h"
 #include "common/controldata_utils.h"
 #include "common/logging.h"
 #include "common/restricted_token.h"
 #include "common/string.h"
-#include "storage/large_object.h"
-#include "pg_getopt.h"
 #include "getopt_long.h"
-
+#include "pg_getopt.h"
+#include "storage/large_object.h"
 
 static ControlFileData ControlFile; /* pg_control values */
 static XLogSegNo newXlogSegNo; /* new XLOG segment # */
index 93165f697cd592645a644035c505b0e0cd3774fa..c903dbb41ef2103675d5b6b4f3a68ebb3445687b 100644 (file)
@@ -12,9 +12,8 @@
 
 #include "postgres_fe.h"
 
-#include "datapagemap.h"
-
 #include "common/logging.h"
+#include "datapagemap.h"
 
 struct datapagemap_iterator
 {
index 03a5fd675f13ff85a4d910b7025e5af853d5d050..294c72c17cab397ab762f4aa9f51c0d018f129e5 100644 (file)
 #include <sys/stat.h>
 #include <unistd.h>
 
-#include "pg_rewind.h"
 #include "fetch.h"
 #include "file_ops.h"
 #include "filemap.h"
+#include "pg_rewind.h"
 
 void
 fetchSourceFileList(void)
index 601f7e9690e6255891d6331cf43f283071034303..21254f39b12ff6959093126bca02e495287d042e 100644 (file)
 #include <sys/stat.h>
 #include <unistd.h>
 
+#include "catalog/pg_tablespace_d.h"
+#include "common/string.h"
 #include "datapagemap.h"
 #include "filemap.h"
 #include "pg_rewind.h"
-
-#include "common/string.h"
-#include "catalog/pg_tablespace_d.h"
 #include "storage/fd.h"
 
 filemap_t  *filemap = NULL;
index f4ebf7d8420b7e90304f74422a9d5fc3c771d22f..2cc87e8d05834b2bf777f1c1106361ce743d048d 100644 (file)
 #include <fcntl.h>
 #include <unistd.h>
 
-#include "pg_rewind.h"
+#include "catalog/pg_type_d.h"
 #include "datapagemap.h"
+#include "fe_utils/connect.h"
 #include "fetch.h"
 #include "file_ops.h"
 #include "filemap.h"
-
-#include "catalog/pg_type_d.h"
-#include "fe_utils/connect.h"
+#include "pg_rewind.h"
 #include "port/pg_bswap.h"
 
 PGconn *conn = NULL;
index 264a8f4db5fbee0a2284cb49e5530383d962ef1d..1d03375a3ec669e6c18b4604ba957794fc75a6fd 100644 (file)
 
 #include <unistd.h>
 
-#include "pg_rewind.h"
-#include "filemap.h"
-
 #include "access/rmgr.h"
 #include "access/xlog_internal.h"
 #include "access/xlogreader.h"
 #include "catalog/pg_control.h"
 #include "catalog/storage_xlog.h"
 #include "commands/dbcommands_xlog.h"
-
+#include "filemap.h"
+#include "pg_rewind.h"
 
 /*
  * RmgrNames is an array of resource manager names, to make error messages
index 875a43b219360197f3968533f6f946a025e0ddc0..e75c7eed1c644b6aeb8931e44b3e5ce2a3f3deb2 100644 (file)
 #include <time.h>
 #include <unistd.h>
 
-#include "pg_rewind.h"
-#include "fetch.h"
-#include "file_ops.h"
-#include "filemap.h"
-
 #include "access/timeline.h"
 #include "access/xlog_internal.h"
 #include "catalog/catversion.h"
 #include "common/file_utils.h"
 #include "common/restricted_token.h"
 #include "fe_utils/recovery_gen.h"
+#include "fetch.h"
+#include "file_ops.h"
+#include "filemap.h"
 #include "getopt_long.h"
+#include "pg_rewind.h"
 #include "storage/bufpage.h"
 
 static void usage(const char *progname);
index 987452c4f41e879e506a3b50e5cb3b30c3b92e9a..a29b56bc15ac5465451b3c4fd37ffa2bf276140d 100644 (file)
@@ -9,10 +9,9 @@
  */
 #include "postgres_fe.h"
 
-#include "pg_rewind.h"
-
 #include "access/timeline.h"
 #include "access/xlog_internal.h"
+#include "pg_rewind.h"
 
 /*
  * This is copy-pasted from the backend readTimeLineHistory, modified to
index 225557e6c57b123b3471b23f645356bae56c14ee..2ca1608bd215d5178ec86b7adf41c70bffb81fb0 100644 (file)
 #include <unistd.h>
 #include <signal.h>
 
-#include "getopt_long.h"
 #include "access/xlogdefs.h"
 #include "common/logging.h"
-
+#include "getopt_long.h"
 
 /*
  * put the temp files in the local directory
index 87b9d328d4cc72dbc4091e1833afb7297db405b8..ff7057db7380fcef968e59154e6fd5bfe1f5efa1 100644 (file)
@@ -14,7 +14,6 @@
 #include "mb/pg_wchar.h"
 #include "pg_upgrade.h"
 
-
 static void check_new_cluster_is_empty(void);
 static void check_databases_are_compatible(void);
 static void check_locale_and_encoding(DbInfo *olddb, DbInfo *newdb);
index 38236415bef99f949418f83051215862306dad2a..93f3c34b749343f8e91bb3c57bb6441d1c46bc7c 100644 (file)
@@ -9,10 +9,10 @@
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
-
 #include <ctype.h>
 
+#include "pg_upgrade.h"
+
 /*
  * get_control_data()
  *
index c1429fe4bfbc43d74ce5e431b2ee2fae834e2fd9..bdb5006fa6399c79ed91982e6c1170ca9fa382a2 100644 (file)
@@ -9,10 +9,8 @@
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
-
 #include "fe_utils/string_utils.h"
-
+#include "pg_upgrade.h"
 
 void
 generate_old_dump(void)
index c7fed24df933856069fb159bfd908699c5c14933..ab64d5f22174f44ba9bae76702e603ec0c5eaa4f 100644 (file)
@@ -9,13 +9,6 @@
 
 #include "postgres_fe.h"
 
-#include "access/visibilitymap.h"
-#include "common/file_perm.h"
-#include "pg_upgrade.h"
-#include "storage/bufpage.h"
-#include "storage/checksum.h"
-#include "storage/checksum_impl.h"
-
 #include <sys/stat.h>
 #include <fcntl.h>
 #ifdef HAVE_COPYFILE_H
 #include <linux/fs.h>
 #endif
 
+#include "access/visibilitymap.h"
+#include "common/file_perm.h"
+#include "pg_upgrade.h"
+#include "storage/bufpage.h"
+#include "storage/checksum.h"
+#include "storage/checksum_impl.h"
 
 #ifdef WIN32
 static int     win32_pghardlink(const char *src, const char *dst);
index 3cbaab6a5e205d5135616764c433cecb99c6a900..ac984db83893389bbfc32dd97bcca2cac7aed366 100644 (file)
@@ -9,11 +9,9 @@
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
-
 #include "access/transam.h"
 #include "catalog/pg_language_d.h"
-
+#include "pg_upgrade.h"
 
 /*
  * qsort comparator for pointers to library names
index 5c7b4337ba4c7ebaae05f89f1947d24127793705..d67d3a489473b541dfd41004dc77479c8f1c7d96 100644 (file)
@@ -9,11 +9,9 @@
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
-
 #include "access/transam.h"
 #include "catalog/pg_class_d.h"
-
+#include "pg_upgrade.h"
 
 static void create_rel_filename_map(const char *old_data, const char *new_data,
                                                                        const DbInfo *old_db, const DbInfo *new_db,
index da9e1da78db1a4a7aaf9aaee1c6626e295a8de2f..14351e80280ad2aa7b22babafceb1256b78ad3d6 100644 (file)
 #include <io.h>
 #endif
 
-#include "getopt_long.h"
 #include "common/string.h"
-#include "utils/pidfile.h"
-
+#include "getopt_long.h"
 #include "pg_upgrade.h"
-
+#include "utils/pidfile.h"
 
 static void usage(void);
 static void check_required_directory(char **dirpath,
index 80ab1b86093c13ea3e25890f191a39f1514eaf73..d3d34018c01a5905b99f20af46c5225a8cdb25df 100644 (file)
@@ -16,7 +16,6 @@
 
 #include "pg_upgrade.h"
 
-
 static int     parallel_jobs;
 
 #ifdef WIN32
index 5b82e0c79bdd006f23ee00e097bdb5b5695c1a04..5154a7160d2964a3400c60bb711073ce1388d488 100644 (file)
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
+#ifdef HAVE_LANGINFO_H
+#include <langinfo.h>
+#endif
+
 #include "catalog/pg_class_d.h"
 #include "common/file_perm.h"
 #include "common/logging.h"
 #include "common/restricted_token.h"
 #include "fe_utils/string_utils.h"
-
-#ifdef HAVE_LANGINFO_H
-#include <langinfo.h>
-#endif
+#include "pg_upgrade.h"
 
 static void prepare_new_cluster(void);
 static void prepare_new_globals(void);
index 0c78073f0eb08b8efc0916920a681ced0bc7e7f0..f9d0812cc5f5732d42f87dab20d5edf51898d8b0 100644 (file)
@@ -9,12 +9,11 @@
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
-
 #include <sys/stat.h>
-#include "catalog/pg_class_d.h"
-#include "access/transam.h"
 
+#include "access/transam.h"
+#include "catalog/pg_class_d.h"
+#include "pg_upgrade.h"
 
 static void transfer_single_new_db(FileNameMap *maps, int size, char *old_tablespace);
 static void transfer_relfile(FileNameMap *map, const char *suffix, bool vm_must_add_frozenbit);
index 6ad4b14e16a36db1b12246eb0f3a897ca7da2df8..30f28bdc2a89d1137a4f8b9fa1de8ec7dc61b6af 100644 (file)
@@ -13,7 +13,6 @@
 #include "fe_utils/string_utils.h"
 #include "pg_upgrade.h"
 
-
 static PGconn *get_db_conn(ClusterInfo *cluster, const char *db_name);
 
 
index d867995cc3d5114d6a063e87b2543fd02f5034d8..46d0bb42631576248234b716f97887fd7c358935 100644 (file)
@@ -9,11 +9,10 @@
 
 #include "postgres_fe.h"
 
-#include "common/username.h"
-#include "pg_upgrade.h"
-
 #include <signal.h>
 
+#include "common/username.h"
+#include "pg_upgrade.h"
 
 LogOpts                log_opts;
 
index 3f7c8c5395b468cc1cfca9a9a101e38e66f7474b..9deb53c8b74c82142da290758e20c9545ce293fc 100644 (file)
@@ -9,12 +9,9 @@
 
 #include "postgres_fe.h"
 
-#include "pg_upgrade.h"
-
 #include "catalog/pg_class_d.h"
 #include "fe_utils/string_utils.h"
-
-
+#include "pg_upgrade.h"
 
 /*
  * new_9_0_populate_pg_largeobject_metadata()
index 0e0dca7d1ad28f632c327a1eedd78e9c980cce7e..7b389a20c965b98b5b7b78620111ad7303b9020e 100644 (file)
@@ -20,8 +20,8 @@
 
 #include <time.h>
 
-#include "utils/datetime.h"
 #include "lib/stringinfo.h"
+#include "utils/datetime.h"
 
 /* copied from timestamp.c */
 pg_time_t
index b79208cd73672be9362d59bba09b0e6a41384670..8e54d7f4e007bf648ffd06d77af885dc6096d470 100644 (file)
 #include <sys/stat.h>
 #include <unistd.h>
 
+#include "access/xlog_internal.h"
 #include "access/xlogreader.h"
 #include "access/xlogrecord.h"
-#include "access/xlog_internal.h"
 #include "access/transam.h"
 #include "common/fe_memutils.h"
 #include "common/logging.h"
 #include "getopt_long.h"
 #include "rmgrdesc.h"
 
-
 static const char *progname;
 
 static int     WalSegSz;
index e72ad0036e18a4d3e673a1a20548a38829d10777..03bcd2299664eafa97e06a85d3ed3cf5ece68a5d 100644 (file)
 #endif
 
 #include "postgres_fe.h"
-#include "common/int.h"
-#include "common/logging.h"
-#include "fe_utils/conditional.h"
-#include "getopt_long.h"
-#include "libpq-fe.h"
-#include "portability/instr_time.h"
 
 #include <ctype.h>
 #include <float.h>
 #endif
 #endif
 
+#include "common/int.h"
+#include "common/logging.h"
+#include "fe_utils/conditional.h"
+#include "getopt_long.h"
+#include "libpq-fe.h"
+#include "pgbench.h"
+#include "portability/instr_time.h"
+
 #ifndef M_PI
 #define M_PI 3.14159265358979323846
 #endif
 
-#include "pgbench.h"
 
 #define ERRCODE_UNDEFINED_TABLE  "42P01"
 
index 4b2679360fc2ebbaae4d82efeae09c9962fd7ae7..90f6380170a91a4446c95fbd78b649c05c76a0d5 100644 (file)
 #include <win32.h>
 #endif
 
-#include "common/logging.h"
-#include "fe_utils/mbprint.h"
-#include "fe_utils/string_utils.h"
-#include "portability/instr_time.h"
-
 #include "command.h"
 #include "common.h"
+#include "common/logging.h"
 #include "copy.h"
 #include "crosstabview.h"
+#include "fe_utils/mbprint.h"
+#include "fe_utils/string_utils.h"
+#include "portability/instr_time.h"
 #include "settings.h"
 
-
 static bool DescribeQuery(const char *query, double *elapsed_msec);
 static bool ExecQueryUsingCursor(const char *query, double *elapsed_msec);
 static bool command_no_begin(const char *query);
index f9e53d6295402c9b2e2f81ffa494a19d9916001c..04e518e64bc715f1a7818140bb1e0fd010b5fa96 100644 (file)
@@ -6,7 +6,6 @@
  * src/bin/psql/copy.c
  */
 #include "postgres_fe.h"
-#include "copy.h"
 
 #include <signal.h>
 #include <sys/stat.h>
 #include <io.h>                                        /* I think */
 #endif
 
+#include "common.h"
+#include "common/logging.h"
+#include "copy.h"
 #include "libpq-fe.h"
 #include "pqexpbuffer.h"
-
-#include "settings.h"
-#include "common.h"
 #include "prompt.h"
+#include "settings.h"
 #include "stringutils.h"
 
-#include "common/logging.h"
-
 /*
  * parse_slash_copy
  * -- parses \copy command line
index 83789cb911afe9391659e6b1f58f8179ba2b684a..701ef3443a68de538eb5fa338ed9d262554fb884 100644 (file)
@@ -8,13 +8,12 @@
 #include "postgres_fe.h"
 
 #include "common.h"
+#include "common/logging.h"
 #include "crosstabview.h"
 #include "pqexpbuffer.h"
 #include "psqlscanslash.h"
 #include "settings.h"
 
-#include "common/logging.h"
-
 /*
  * Value/position from the resultset that goes into the horizontal or vertical
  * crosstabview header.
index d7c0fc0c1e70920eb76532f08a5f5356d5f8cbcd..b3b9313b36f30acb0089d9a05ea28b0d1615ceb9 100644 (file)
 #include "catalog/pg_cast_d.h"
 #include "catalog/pg_class_d.h"
 #include "catalog/pg_default_acl_d.h"
-
+#include "common.h"
 #include "common/logging.h"
+#include "describe.h"
 #include "fe_utils/mbprint.h"
 #include "fe_utils/print.h"
 #include "fe_utils/string_utils.h"
-
-#include "common.h"
-#include "describe.h"
 #include "settings.h"
 #include "variables.h"
 
-
 static bool describeOneTableDetails(const char *schemaname,
                                                                        const char *relationname,
                                                                        const char *oid,
index 59ea8cc16e397c9cc40d6d5417212439c5e0b50e..0f58eeba024b42d8828375afa362d5f56326812b 100644 (file)
 #include <termios.h>
 #endif
 
+#include "common.h"
 #include "common/logging.h"
 #include "common/username.h"
-
-#include "common.h"
 #include "help.h"
 #include "input.h"
 #include "settings.h"
index 5a18ac9bbc4b29f4f60aaa093ac1285b61aec975..5798e6e7d68a89d9eb91eb6bf537a58554e83598 100644 (file)
 #include <fcntl.h>
 #include <limits.h>
 
+#include "common.h"
+#include "common/logging.h"
 #include "input.h"
 #include "settings.h"
 #include "tab-complete.h"
-#include "common.h"
-
-#include "common/logging.h"
 
 #ifndef WIN32
 #define PSQLHISTORY ".psql_history"
index 2713f15d4f3d1c3e8a72c7de7363196516be7cd6..042403e0f78d6d3e620ef8f1e96e7ed0f910b738 100644 (file)
@@ -6,12 +6,11 @@
  * src/bin/psql/large_obj.c
  */
 #include "postgres_fe.h"
-#include "large_obj.h"
 
-#include "settings.h"
 #include "common.h"
-
 #include "common/logging.h"
+#include "large_obj.h"
+#include "settings.h"
 
 static void print_lo_result(const char *fmt,...) pg_attribute_printf(1, 2);
 
index e386d9888d7194b75f6ede91333de51d913bcb7e..b3a840756af97a5fdca8f02752587c6959fa2bde 100644 (file)
@@ -6,18 +6,16 @@
  * src/bin/psql/mainloop.c
  */
 #include "postgres_fe.h"
-#include "mainloop.h"
 
 #include "command.h"
 #include "common.h"
+#include "common/logging.h"
 #include "input.h"
+#include "mainloop.h"
+#include "mb/pg_wchar.h"
 #include "prompt.h"
 #include "settings.h"
 
-#include "common/logging.h"
-#include "mb/pg_wchar.h"
-
-
 /* callback functions for our flex lexer */
 const PsqlScanCallbacks psqlscan_callbacks = {
        psql_get_variable,
index 0fcb8c7783210894b1a5a2ebaffc2041be3810fe..195192a95d611b19711d878e9b6d29e61811abb2 100644 (file)
 #endif
 
 #include "common.h"
+#include "common/string.h"
 #include "input.h"
 #include "prompt.h"
 #include "settings.h"
 
-#include "common/string.h"
-
 /*--------------------------
  * get_prompt
  *
index e4c0a7eacbfc73f3409da168d173836b5e6c6f78..0d941ef5ba56c529e32cf7496e5d7bb374f13dbc 100644 (file)
 #include <win32.h>
 #endif                                                 /* WIN32 */
 
-#include "getopt_long.h"
-
-#include "common/logging.h"
-#include "fe_utils/print.h"
-
 #include "command.h"
 #include "common.h"
+#include "common/logging.h"
 #include "describe.h"
+#include "fe_utils/print.h"
+#include "getopt_long.h"
 #include "help.h"
 #include "input.h"
 #include "mainloop.h"
 #include "settings.h"
 
-
-
 /*
  * Global psql options
  */
index 1d2a31cd65de0d8a0b7474baaf277eff4c12baf6..3f7b64143f8129f676f5f3a857bdb8ff4f9a378e 100644 (file)
@@ -8,10 +8,8 @@
 #include "postgres_fe.h"
 
 #include "common.h"
-#include "variables.h"
-
 #include "common/logging.h"
-
+#include "variables.h"
 
 /*
  * Check whether a variable's name is allowed.
index e3325573b285d1634550334a49899598d1fc12a2..ea5ca8d7edc8cc5245f572995b13a9dd7ac8f176 100644 (file)
@@ -39,9 +39,8 @@
 #endif
 
 #include "common/shortest_dec.h"
-
-#include "ryu_common.h"
 #include "digit_table.h"
+#include "ryu_common.h"
 
 #define FLOAT_MANTISSA_BITS 23
 #define FLOAT_EXPONENT_BITS 8
index e41f42ea981708d636bb09aecebec0f94b00854c..1f8bde84433de8dd6cfada270c2f69f9f4b67ec3 100644 (file)
 #include <termios.h>
 #endif
 
-#include "fe_utils/print.h"
-
 #include "catalog/pg_type_d.h"
 #include "fe_utils/mbprint.h"
-
+#include "fe_utils/print.h"
 
 /*
  * If the calling program doesn't have any mechanism for setting
index 6641f95f0713baf1d70ca568e1529d0f57fffc36..aec01c0caa9e8585c20ecce7a622fabc72b76946 100644 (file)
@@ -10,9 +10,8 @@
 #include "postgres_fe.h"
 
 #include "common/logging.h"
-#include "fe_utils/string_utils.h"
 #include "fe_utils/recovery_gen.h"
-
+#include "fe_utils/string_utils.h"
 
 static char *escape_quotes(const char *src);
 
index 8c3a603cf1dba9e92c9420152c591e357a0057f7..b07f14255cdcc03b9532458fb23dc37be417f20c 100644 (file)
 
 #include <ctype.h>
 
-#include "fe_utils/string_utils.h"
-
 #include "common/keywords.h"
-
+#include "fe_utils/string_utils.h"
 
 static PQExpBuffer defaultGetLocalPQExpBuffer(void);
 
index 6ef1fadb7fc824f35b5978515009da8d54c8070d..bbaf4503c3b25ad047f0d31e9ceaeba1e9566d3d 100644 (file)
@@ -7,14 +7,14 @@
 #include <ctype.h>
 #include <limits.h>
 
-#include <ecpgtype.h>
-#include <ecpg_informix.h>
-#include <pgtypes_error.h>
-#include <pgtypes_date.h>
-#include <pgtypes_numeric.h>
-#include <sqltypes.h>
-#include <sqlca.h>
-#include <ecpgerrno.h>
+#include "ecpg_informix.h"
+#include "ecpgerrno.h"
+#include "ecpgtype.h"
+#include "pgtypes_date.h"
+#include "pgtypes_error.h"
+#include "pgtypes_numeric.h"
+#include "sqlca.h"
+#include "sqltypes.h"
 
 /* this is also defined in ecpglib/misc.c, by defining it twice we don't have to export the symbol */
 
index b4f6089c282c0cad72ad52c8459a962b29f69c31..1cb52116f95d7a6c5a8d2fa82fb7eb9fe1adb8a1 100644 (file)
@@ -4,10 +4,10 @@
 #include "postgres_fe.h"
 
 #include "ecpg-pthread-win32.h"
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
+#include "ecpgtype.h"
 #include "sqlca.h"
 
 #ifdef ENABLE_THREAD_SAFETY
index 81f94cc12b80e7a413a37e31d61f86c454f164ee..7d2a78a60d826923999ef0a4bc568b7f3c13b28a 100644 (file)
@@ -5,15 +5,15 @@
 
 #include <math.h>
 
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
-#include "sqlca.h"
-#include "pgtypes_numeric.h"
+#include "ecpgtype.h"
 #include "pgtypes_date.h"
-#include "pgtypes_timestamp.h"
 #include "pgtypes_interval.h"
+#include "pgtypes_numeric.h"
+#include "pgtypes_timestamp.h"
+#include "sqlca.h"
 
 /* returns true if character c is a delimiter for the given array type */
 static bool
index ef500a915d62932ee8719dc2432f1492f2a6a212..ead8778ca83e821eb3c3a3d1933647e40b0fbf5c 100644 (file)
@@ -7,12 +7,11 @@
 #include "postgres_fe.h"
 
 #include "catalog/pg_type_d.h"
-
 #include "ecpg-pthread-win32.h"
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
+#include "ecpgtype.h"
 #include "sqlca.h"
 #include "sqlda.h"
 #include "sql3types.h"
index 9c56991a1e82116b4e1eb5f80e1f1c967f5d8740..a4e3c0d01f8c6f0e022b77db95453dbd0bddc731 100644 (file)
@@ -4,9 +4,9 @@
 #include "postgres_fe.h"
 
 #include "ecpgerrno.h"
-#include "ecpgtype.h"
 #include "ecpglib.h"
 #include "ecpglib_extern.h"
+#include "ecpgtype.h"
 #include "sqlca.h"
 
 void
index 7c9cb760a9969ca24826d4c27d470f9482c0dc8a..23cc86941cf8253c078e393b77006dfc606182d7 100644 (file)
 #include <math.h>
 
 #include "catalog/pg_type_d.h"
-
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
-#include "sqlca.h"
-#include "sqlda-native.h"
-#include "sqlda-compat.h"
-#include "sql3types.h"
-#include "pgtypes_numeric.h"
+#include "ecpgtype.h"
 #include "pgtypes_date.h"
-#include "pgtypes_timestamp.h"
 #include "pgtypes_interval.h"
+#include "pgtypes_numeric.h"
+#include "pgtypes_timestamp.h"
+#include "sql3types.h"
+#include "sqlca.h"
+#include "sqlda-compat.h"
+#include "sqlda-native.h"
 
 /*
  *     This function returns a newly malloced string that has ' and \
index 52ca1c5c687f80b03aa1dad22a2ef8d97b08160a..bd8125105495b7c2e70765dd96b8bc39927437e0 100644 (file)
@@ -4,10 +4,10 @@
 #include "postgres_fe.h"
 
 #include "ecpg-pthread-win32.h"
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
+#include "ecpgtype.h"
 
 void
 ecpg_free(void *ptr)
index 2eec54a2d9972a5ed46ada106fd2fe4ec5b9aaf3..647da14fce491d5c60f2c4306df778519bcd70fd 100644 (file)
@@ -5,17 +5,18 @@
 
 #include <limits.h>
 #include <unistd.h>
+
 #include "ecpg-pthread-win32.h"
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
-#include "sqlca.h"
-#include "pgtypes_numeric.h"
+#include "ecpgtype.h"
 #include "pgtypes_date.h"
-#include "pgtypes_timestamp.h"
 #include "pgtypes_interval.h"
+#include "pgtypes_numeric.h"
+#include "pgtypes_timestamp.h"
 #include "pg_config_paths.h"
+#include "sqlca.h"
 
 #ifdef HAVE_LONG_LONG_INT
 #ifndef LONG_LONG_MIN
index 6e7adb94f264ef01f0b9bc0fcd8a8c98ed4afaad..b9653c01feafe92941ec80c731ce642379a67b62 100644 (file)
@@ -5,10 +5,10 @@
 
 #include <ctype.h>
 
-#include "ecpgtype.h"
-#include "ecpglib.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
+#include "ecpgtype.h"
 #include "sqlca.h"
 
 #define STMTID_SIZE 32
index 3fb0d829d37c1e76774f2903fc7d5f72b8be87c9..081e32666f6ac7eb45d3e3171f2adb5a52463cf3 100644 (file)
 #include "postgres_fe.h"
 
 #include "catalog/pg_type_d.h"
-
-#include "ecpg-pthread-win32.h"
 #include "decimal.h"
-#include "ecpgtype.h"
-#include "ecpglib.h"
+#include "ecpg-pthread-win32.h"
 #include "ecpgerrno.h"
+#include "ecpglib.h"
 #include "ecpglib_extern.h"
+#include "ecpgtype.h"
 #include "sqlca.h"
-#include "sqlda-native.h"
 #include "sqlda-compat.h"
+#include "sqlda-native.h"
 
 /*
  * Compute the next variable's offset with
index 9251450f9e667de04d5ae22bb8632caa5fd8e4bf..1d482c4fa61ca1c282774064c19ffd908c6a296e 100644 (file)
@@ -4,12 +4,11 @@
 #include "postgres_fe.h"
 
 #include "catalog/pg_type_d.h"
-
-#include "ecpgtype.h"
 #include "ecpglib.h"
 #include "ecpglib_extern.h"
-#include "sqltypes.h"
+#include "ecpgtype.h"
 #include "sql3types.h"
+#include "sqltypes.h"
 
 /*
  * This function is used to generate the correct type names.
index abcf7f5dbef8a652b61c6d32157494d71d9b201f..8972229ca2f4097d04746029bb7d4bd02033d105 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "postgres_fe.h"
 
-#include "pgtypeslib_extern.h"
 #include "pgtypes.h"
+#include "pgtypeslib_extern.h"
 
 /* Return value is zero-filled. */
 char *
index 9ee460b9a1f9024177b7ec860881e5b498abdea8..71dc1a5ff8bdaec3a55be96061399acfe8bc982c 100644 (file)
@@ -6,10 +6,10 @@
 #include <ctype.h>
 #include <limits.h>
 
-#include "pgtypeslib_extern.h"
 #include "dt.h"
-#include "pgtypes_error.h"
 #include "pgtypes_date.h"
+#include "pgtypes_error.h"
+#include "pgtypeslib_extern.h"
 
 date *
 PGTYPESdate_new(void)
index 29c111754695025bd90c57e15b71ecf9b3510388..c22f6576740f011c657b12b167dc94069ce9b9d5 100644 (file)
@@ -7,9 +7,9 @@
 #include <math.h>
 
 #include "common/string.h"
-#include "pgtypeslib_extern.h"
 #include "dt.h"
 #include "pgtypes_timestamp.h"
+#include "pgtypeslib_extern.h"
 
 const int      day_tab[2][13] = {
        {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31, 0},
index 3ff8a1025a38751a29af44ee915339b280874eff..5b3c9a71e30ac77a91bebffd30244762ebbb4891 100644 (file)
@@ -1,6 +1,7 @@
 /* src/interfaces/ecpg/pgtypeslib/interval.c */
 
 #include "postgres_fe.h"
+
 #include <time.h>
 #include <math.h>
 #include <limits.h>
 #endif
 
 #include "common/string.h"
-
-#include "pgtypeslib_extern.h"
 #include "dt.h"
 #include "pgtypes_error.h"
 #include "pgtypes_interval.h"
+#include "pgtypeslib_extern.h"
 
 /* copy&pasted from .../src/backend/utils/adt/datetime.c
  * and changesd struct pg_tm to struct tm
index 22088bae8e44451f0f1a4b7aacb745595a379d5e..b6ca2d3252fdd1a85f2e508b6fa7b525a7e4311d 100644 (file)
@@ -1,12 +1,14 @@
 /* src/interfaces/ecpg/pgtypeslib/numeric.c */
 
 #include "postgres_fe.h"
+
 #include <ctype.h>
 #include <float.h>
 #include <limits.h>
 
-#include "pgtypeslib_extern.h"
 #include "pgtypes_error.h"
+#include "pgtypes_numeric.h"
+#include "pgtypeslib_extern.h"
 
 #define Max(x, y)                              ((x) > (y) ? (x) : (y))
 #define Min(x, y)                              ((x) < (y) ? (x) : (y))
@@ -20,7 +22,6 @@
                                                  free(buf); \
                  } while (0)
 
-#include "pgtypes_numeric.h"
 
 #if 0
 /* ----------
index 2be151f7e66691b1301cf8a938d022ccdc8d9736..7816e6fdc05b66a9941e3474a2bcfca43a73ffca 100644 (file)
 #error -ffast-math is known to break this code
 #endif
 
-#include "pgtypeslib_extern.h"
 #include "dt.h"
-#include "pgtypes_timestamp.h"
 #include "pgtypes_date.h"
-
+#include "pgtypes_timestamp.h"
+#include "pgtypeslib_extern.h"
 
 static int64
 time2t(const int hour, const int min, const int sec, const fsec_t fsec)
index 80aa7d5339c788686cbb42052f63dbde82fb8f2f..e51c036101ea8ef5502f3b2501b705cfb67f93e5 100644 (file)
@@ -9,11 +9,10 @@
  */
 #include "postgres_fe.h"
 
-#include "preproc_extern.h"
-#include "preproc.h"
-
 /* ScanKeywordList lookup data for C keywords */
 #include "c_kwlist_d.h"
+#include "preproc_extern.h"
+#include "preproc.h"
 
 /* Token codes for C keywords */
 #define PG_KEYWORD(kwname, value) value,
index 4839c37bbca92f0066437b1b13493ecec985752a..a2db06fadad94ca611be11d42debb3029e16cc83 100644 (file)
 
 #include <ctype.h>
 
-#include "preproc_extern.h"
-#include "preproc.h"
-
 /* ScanKeywordList lookup data for ECPG keywords */
 #include "ecpg_kwlist_d.h"
+#include "preproc_extern.h"
+#include "preproc.h"
 
 /* Token codes for ECPG keywords */
 #define PG_KEYWORD(kwname, value) value,
index a690f3ba3ad757c93a89fcd58b333f7322bb33a0..2364dda9874faf72546128467b3d64fe5d6bc939 100644 (file)
@@ -40,9 +40,8 @@
 
 #include "common/md5.h"
 #include "common/scram-common.h"
-#include "libpq-fe.h"
 #include "fe-auth.h"
-
+#include "libpq-fe.h"
 
 #ifdef ENABLE_GSS
 /*
index 99051231a6e0a43290c8b265a3cd13c948c1b266..dcd86ee80436fc311835b4d57861cbfa1455d794 100644 (file)
 #include <time.h>
 #include <unistd.h>
 
+#include "common/ip.h"
+#include "common/link-canary.h"
+#include "common/scram-common.h"
+#include "common/string.h"
+#include "fe-auth.h"
 #include "libpq-fe.h"
 #include "libpq-int.h"
-#include "fe-auth.h"
+#include "mb/pg_wchar.h"
 #include "pg_config_paths.h"
+#include "port/pg_bswap.h"
 
 #ifdef WIN32
 #include "win32.h"
@@ -70,14 +76,6 @@ static int   ldapServiceLookup(const char *purl, PQconninfoOption *options,
                                                          PQExpBuffer errorMessage);
 #endif
 
-#include "common/ip.h"
-#include "common/link-canary.h"
-#include "common/scram-common.h"
-#include "common/string.h"
-#include "mb/pg_wchar.h"
-#include "port/pg_bswap.h"
-
-
 #ifndef WIN32
 #define PGPASSFILE ".pgpass"
 #else
index b3c59a099233333b8dc62c8c4d13f6e5ca3b3c89..051f548594dc1444cd6f919b3a31ce284ff96818 100644 (file)
 #include <fcntl.h>
 #include <limits.h>
 
-#include "libpq-fe.h"
-#include "libpq-int.h"
-
-#include "mb/pg_wchar.h"
-
 #ifdef WIN32
 #include "win32.h"
 #else
 #include <unistd.h>
 #endif
 
+#include "libpq-fe.h"
+#include "libpq-int.h"
+#include "mb/pg_wchar.h"
+
 /* keep this in same order as ExecStatusType in libpq-fe.h */
 char      *const pgresStatus[] = {
        "PGRES_EMPTY_QUERY",
index 18fec4a17314c47a6acc99b59c20748387373512..a7c08c5c88a4b4329466ddc39f509b3551bab90e 100644 (file)
@@ -50,9 +50,8 @@
 #include "libpq-fe.h"
 #include "libpq-int.h"
 #include "mb/pg_wchar.h"
-#include "port/pg_bswap.h"
 #include "pg_config_paths.h"
-
+#include "port/pg_bswap.h"
 
 static int     pqPutMsgBytes(const void *buf, size_t len, PGconn *conn);
 static int     pqSendSome(PGconn *conn, int len);
index 0e36974fc4a164fe9aba8131dd705bcdc1e3303d..e71e25ae88ae1a912c59927fcd685ec134b5a8e6 100644 (file)
 #include <ctype.h>
 #include <fcntl.h>
 
-#include "libpq-fe.h"
-#include "libpq-int.h"
-#include "port/pg_bswap.h"
-
-
 #ifdef WIN32
 #include "win32.h"
 #else
@@ -31,6 +26,9 @@
 #endif
 #endif
 
+#include "libpq-fe.h"
+#include "libpq-int.h"
+#include "port/pg_bswap.h"
 
 static int     getRowDescriptions(PGconn *conn);
 static int     getAnotherTuple(PGconn *conn, bool binary);
index b04f7ec123b3aade8d893cbe1a4488faea6c3fea..c97841eb13bd3c742cb1d506b7331dd857777d2e 100644 (file)
 #include <ctype.h>
 #include <fcntl.h>
 
-#include "libpq-fe.h"
-#include "libpq-int.h"
-
-#include "mb/pg_wchar.h"
-#include "port/pg_bswap.h"
-
 #ifdef WIN32
 #include "win32.h"
 #else
 #endif
 #endif
 
+#include "libpq-fe.h"
+#include "libpq-int.h"
+#include "mb/pg_wchar.h"
+#include "port/pg_bswap.h"
 
 /*
  * This macro lists the backend message types that could be "long" (more
index 095750db1faaa45ff20dd0f74adf5e83e4608e1f..a1c1d122570575daa8a64cbafb51c030c003d4a2 100644 (file)
@@ -13,9 +13,9 @@
 
 #include "postgres_fe.h"
 
+#include "fe-gssapi-common.h"
 #include "libpq-fe.h"
 #include "libpq-int.h"
-#include "fe-gssapi-common.h"
 #include "port/pg_bswap.h"
 
 /*
index b8191b4c8f8a8f5314745b0fd97de8150a300d06..e55b375c516e471409eb862898441c6c82f32057 100644 (file)
 #include <fcntl.h>
 #include <ctype.h>
 
-#include "libpq-fe.h"
-#include "fe-auth.h"
-#include "libpq-int.h"
-
 #ifdef WIN32
 #include "win32.h"
 #else
 #endif
 #endif
 
+#include "fe-auth.h"
+#include "libpq-fe.h"
+#include "libpq-int.h"
+
 /*
  * Macros to handle disabling and then restoring the state of SIGPIPE handling.
  * On Windows, these are all no-ops since there's no SIGPIPEs.
index 0c24ba692d2893ad5196925e5c242d9bdedf70e6..3fb8fc7bad2b348b11d3b557feed305646d3dc83 100644 (file)
@@ -24,6 +24,7 @@
 #include "funcapi.h"
 #include "nodes/makefuncs.h"
 #include "parser/parse_type.h"
+#include "plpgsql.h"
 #include "utils/builtins.h"
 #include "utils/guc.h"
 #include "utils/lsyscache.h"
@@ -33,9 +34,6 @@
 #include "utils/syscache.h"
 #include "utils/typcache.h"
 
-#include "plpgsql.h"
-
-
 /* ----------
  * Our own local and global variables
  * ----------
index 345065e305d7ff1f20ab1e0563b20198d5f2d378..fd799b724dae53557d71a2cd6c9b61a3cdf9e5bf 100644 (file)
@@ -34,6 +34,7 @@
 #include "parser/parse_coerce.h"
 #include "parser/parse_type.h"
 #include "parser/scansup.h"
+#include "plpgsql.h"
 #include "storage/proc.h"
 #include "tcop/tcopprot.h"
 #include "tcop/utility.h"
@@ -48,9 +49,6 @@
 #include "utils/syscache.h"
 #include "utils/typcache.h"
 
-#include "plpgsql.h"
-
-
 typedef struct
 {
        int                     nargs;                  /* number of arguments */
index 053f83dc7465912179ae3cbb0594219f1aadf17c..2d4616c89382a5275ef1e7af298987a88a8e0f4f 100644 (file)
 
 #include "postgres.h"
 
-#include "utils/memutils.h"
-
 #include "plpgsql.h"
-
+#include "utils/memutils.h"
 
 /* ----------
  * Local variables for namespace handling
index ce03f1ef840d4814b1b72d1d70160c936fbc1eb2..e92deb32ca4de385055853cac8b1a53415d93365 100644 (file)
 #include "catalog/pg_type.h"
 #include "funcapi.h"
 #include "miscadmin.h"
+#include "plpgsql.h"
 #include "utils/builtins.h"
 #include "utils/guc.h"
 #include "utils/lsyscache.h"
 #include "utils/syscache.h"
 #include "utils/varlena.h"
 
-#include "plpgsql.h"
-
-
 static bool plpgsql_extra_checks_check_hook(char **newvalue, void **extra, GucSource source);
 static void plpgsql_extra_warnings_assign_hook(const char *newvalue, void *extra);
 static void plpgsql_extra_errors_assign_hook(const char *newvalue, void *extra);
index ebe449ec8c60db625fe58a5f3728adf29ba1135f..de725d36d5743b27ad4354f8c592d8cfc0a7f021 100644 (file)
  */
 #include "c.h"
 
-#include "port/pg_crc32c.h"
-
 #include <arm_acle.h>
 
+#include "port/pg_crc32c.h"
+
 pg_crc32c
 pg_comp_crc32c_armv8(pg_crc32c crc, const void *data, size_t len)
 {
index ef56cff4e12885715bf32f5e981b9a63c7837046..a81718b1c0384abd4cacb3b59d1c1d24a10dfa05 100644 (file)
  */
 #include "c.h"
 
-#include "port/pg_crc32c.h"
-
 #include <nmmintrin.h>
 
+#include "port/pg_crc32c.h"
+
 pg_crc32c
 pg_comp_crc32c_sse42(pg_crc32c crc, const void *data, size_t len)
 {
index f1da959dacf578727cc3b5bc8c1a15fac2c80ba1..4afe9f2533482b72b413ee81464fb4a7e577bb99 100644 (file)
@@ -1,7 +1,9 @@
 #include "c.h"
-#include "pgtar.h"
+
 #include <sys/stat.h>
 
+#include "pgtar.h"
+
 /*
  * Print a numeric field in a tar header.  The field starts at *s and is of
  * length len; val is the value to be written.
index 556b46d93f401563714f78254aa79db0abb5b106..b50c1897324f2ffc9f72fe6732fcd3040e98f437 100644 (file)
 #endif
 
 #include "datatype/timestamp.h"
+#include "isolationtester.h"
 #include "libpq-fe.h"
-#include "pqexpbuffer.h"
 #include "pg_getopt.h"
-
-#include "isolationtester.h"
+#include "pqexpbuffer.h"
 
 #define PREP_WAITING "isolationtester_waiting"
 
index bab073bcecc8a215b830cb7399793232db69680e..7e9d7de70c3ebcd5f372ca14af2141bc1e4e5613 100644 (file)
  */
 #include "postgres.h"
 
-#include "fmgr.h"
 #include "access/ginblock.h"
 #include "access/gin_private.h"
 #include "access/htup_details.h"
+#include "fmgr.h"
 
 PG_MODULE_MAGIC;
 
index e3925a156d61ba6c9a58e5124e0697e81d3eee2b..82d856329c525d7e12aa6714d95e824805496815 100644 (file)
 
 #include "fmgr.h"
 #include "lib/integerset.h"
+#include "miscadmin.h"
 #include "nodes/bitmapset.h"
-#include "utils/memutils.h"
-#include "utils/timestamp.h"
 #include "storage/block.h"
 #include "storage/itemptr.h"
-#include "miscadmin.h"
+#include "utils/memutils.h"
+#include "utils/timestamp.h"
 
 /*
  * If you enable this, the "pattern" tests will print information about
index 10379bc59c0ecae89fef85391d0bc63baa868966..f576ecb09fb2ee68d915cf3b7597178b2c51804f 100644 (file)
 
 #include "postgres.h"
 
+#include "catalog/pg_type.h"
 #include "fmgr.h"
 #include "miscadmin.h"
-
-#include "test_rls_hooks.h"
-
-#include "catalog/pg_type.h"
-#include "nodes/makefuncs.h"
 #include "nodes/makefuncs.h"
 #include "parser/parse_clause.h"
 #include "parser/parse_collate.h"
 #include "parser/parse_node.h"
 #include "parser/parse_relation.h"
 #include "rewrite/rowsecurity.h"
+#include "test_rls_hooks.h"
 #include "utils/acl.h"
 #include "utils/rel.h"
 #include "utils/relcache.h"
index a3181685f6972af19bd337aa09c50b2790bc97d1..c1a0fa4580cf4ff2765026ede10d6b1cdf43e4eb 100644 (file)
@@ -20,9 +20,8 @@
 #include "postmaster/bgworker.h"
 #include "storage/procsignal.h"
 #include "storage/shm_toc.h"
-#include "utils/memutils.h"
-
 #include "test_shm_mq.h"
+#include "utils/memutils.h"
 
 typedef struct
 {
index 3a3947210886157c5c21df6a0e247cf5ae3e4cc6..6554ce214bc02c3a5e08d51dc2f91667a45c58d6 100644 (file)
 #include <sys/resource.h>
 #endif
 
-#include "pg_regress.h"
-
 #include "common/logging.h"
 #include "common/restricted_token.h"
 #include "common/username.h"
 #include "getopt_long.h"
 #include "libpq/pqcomm.h"              /* needed for UNIXSOCK_PATH() */
 #include "pg_config_paths.h"
+#include "pg_regress.h"
 #include "portability/instr_time.h"
 
 /* for resultmap we need a list of pairs of strings */
index cb8ef53fef1576b02aebe4aa2ae4dab3e49f89e5..2f66d76ab3460eef9e33660053aef01c3de08d58 100644 (file)
 #include "port/atomics.h"
 #include "utils/builtins.h"
 #include "utils/geo_decls.h"
+#include "utils/memutils.h"
 #include "utils/rel.h"
 #include "utils/typcache.h"
-#include "utils/memutils.h"
-
 
 #define EXPECT_TRUE(expr)      \
        do { \