Fix a passel of recently-committed violations of the rule 'thou shalt
authorTom Lane <tgl@sss.pgh.pa.us>
Fri, 14 Jul 2006 05:28:29 +0000 (05:28 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Fri, 14 Jul 2006 05:28:29 +0000 (05:28 +0000)
have no other gods before c.h'.  Also remove some demonstrably redundant
#include lines, mostly of <errno.h> which was added to c.h years ago.

40 files changed:
contrib/btree_gist/btree_numeric.c
contrib/btree_gist/btree_utils_num.h
contrib/btree_gist/btree_utils_var.c
contrib/btree_gist/btree_utils_var.h
contrib/chkpass/chkpass.c
contrib/fuzzystrmatch/dmetaphone.c
contrib/pg_trgm/trgm.h
contrib/tsearch2/common.c
contrib/tsearch2/gendict/dict_snowball.c.IN
contrib/tsearch2/gendict/dict_tmpl.c.IN
contrib/tsearch2/ispell/regis.c
contrib/tsearch2/ispell/spell.c
contrib/tsearch2/ispell/spell.h
src/backend/executor/nodeSubplan.c
src/backend/libpq/auth.c
src/backend/libpq/pqcomm.c
src/backend/libpq/pqformat.c
src/backend/port/dynloader/aix.c
src/backend/port/ipc_test.c
src/backend/port/posix_sema.c
src/backend/port/sysv_sema.c
src/backend/port/sysv_shmem.c
src/backend/port/win32/shmem.c
src/backend/storage/file/buffile.c
src/backend/storage/freespace/freespace.c
src/backend/storage/ipc/ipc.c
src/backend/storage/smgr/md.c
src/backend/utils/adt/datetime.c
src/backend/utils/adt/float.c
src/backend/utils/adt/numeric.c
src/backend/utils/adt/pg_lzcompress.c
src/backend/utils/adt/tid.c
src/bin/psql/help.c
src/bin/psql/mainloop.h
src/interfaces/ecpg/ecpglib/error.c
src/interfaces/ecpg/ecpglib/execute.c
src/interfaces/ecpg/preproc/pgc.l
src/interfaces/libpq/fe-misc.c
src/interfaces/libpq/fe-protocol2.c
src/timezone/pgtz.c

index a6a03c8995bf2f262b3df94e19db2cd7dc28afce..639b575cb3f7fa4a1afe1a839f8c26eb969a47d0 100644 (file)
@@ -1,7 +1,8 @@
+#include "btree_gist.h"
+
 #include <math.h>
 #include <float.h>
 
-#include "btree_gist.h"
 #include "btree_utils_var.h"
 #include "utils/builtins.h"
 #include "utils/numeric.h"
index 1ea022e90f55d02086b8f0a11955ac2c7f78f92f..dcaa94bbeeee4b4b092ca0dce3c2d42cbd15bea3 100644 (file)
@@ -1,11 +1,11 @@
 #ifndef __BTREE_UTILS_NUM_H__
 #define __BTREE_UTILS_NUM_H__
 
+#include "btree_gist.h"
+
 #include <math.h>
 #include <float.h>
 
-#include "btree_gist.h"
-
 typedef char GBT_NUMKEY;
 
 /* Better readable key */
index 1a6f1fdadfe4bef3ab1834f144684aeebf6a96b5..1f5ea126920a19e95bbd62759451df271bc0d206 100644 (file)
@@ -1,8 +1,9 @@
+#include "btree_gist.h"
+
 #include <math.h>
 #include <limits.h>
 #include <float.h>
 
-#include "btree_gist.h"
 #include "btree_utils_var.h"
 #include "utils/pg_locale.h"
 #include "utils/builtins.h"
index 21a6cbd8e273b6019d76e075de2d1e2af6dd34fd..0c723e91ac31e92ca4e11e8147edc10de10c9cbc 100644 (file)
@@ -1,10 +1,10 @@
 #ifndef __BTREE_UTILS_VAR_H__
 #define __BTREE_UTILS_VAR_H__
 
-#include "mb/pg_wchar.h"
-
 #include "btree_gist.h"
 
+#include "mb/pg_wchar.h"
+
 /* Variable length key */
 typedef bytea GBT_VARKEY;
 
index e8ad19971159c4e765595a11bdaecacbd961c98c..9a92ca71b0dccd82c3f74a8040699b02487af278 100644 (file)
@@ -10,8 +10,6 @@
 
 #include "postgres.h"
 
-#include <stdio.h>
-#include <string.h>
 #include <time.h>
 #include <unistd.h>
 #ifdef HAVE_CRYPT_H
index 850954343385b4f874fa4f9e6e757cbeb9517143..9690132c7ac8d9717e583e51ef1627b994bda7a5 100644 (file)
@@ -50,7 +50,7 @@
 
 
 /*
- * $Revision: 1.7 $
+ * $Revision: 1.8 $
  * $Id$
  */
 
@@ -106,8 +106,8 @@ The remaining code is authored by Andrew Dunstan <amdunstan@ncshp.org> and
 #ifndef DMETAPHONE_MAIN
 
 #include "postgres.h"
+
 #include "fmgr.h"
-#include "utils/elog.h"
 
 /* turn off assertions for embedded function */
 #define NDEBUG
index d6ba0405053625a9cdad3e4dabfb3e4c84c5b468..b7674c52b583c35c299a81ceb46ab9962d35b33c 100644 (file)
@@ -6,8 +6,6 @@
 #include "access/gist.h"
 #include "access/itup.h"
 #include "utils/builtins.h"
-#include "utils/elog.h"
-#include "utils/palloc.h"
 #include "storage/bufpage.h"
 
 /* options */
index 35fb9ffcb8a78555f236379524f7cbdffdfc886c..6192821344370785bc6d1e00e978894956875e85 100644 (file)
@@ -1,6 +1,5 @@
 #include "postgres.h"
 
-#include "postgres.h"
 #include "fmgr.h"
 #include "catalog/pg_namespace.h"
 #include "catalog/pg_proc.h"
index 7d080fb447fab18cae1af1ef53852e410db0f4f1..57289458eae3573e3fc8c09e4dd336f777efefa5 100644 (file)
@@ -5,9 +5,6 @@
  * http://snowball.tartarus.org/ 
  * Teodor Sigaev <teodor@sigaev.ru>
  */
-#include <stdlib.h>
-#include <string.h>
-
 #include "postgres.h"
 
 #include "dict.h"
index b473dd86310f11af7f1a6fb37176c5a66b0885be..47d320d64fe6aff3cba16f35c88431cdf4dcd8c2 100644 (file)
@@ -4,10 +4,6 @@
  * example of dictionary 
  * Teodor Sigaev <teodor@sigaev.ru>
  */
-#include <errno.h>
-#include <stdlib.h>
-#include <string.h>
-
 #include "postgres.h"
 
 #include "dict.h"
index 20b6bddecf658afaf570d09e291bb6cfcb099e4a..4be863431d1bd895a89665fd94d56fb47f5e41d9 100644 (file)
@@ -1,7 +1,3 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
 #include "regis.h"
 #include "ts_locale.h"
 #include "common.h"
index 28f38eefd32b71aaa85aeee5c5987f46686e1eb8..4e199f4bc07a6cc5f18494a7abd827ac4866661c 100644 (file)
@@ -1,10 +1,7 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-
 #include "postgres.h"
 
+#include <ctype.h>
+
 #include "spell.h"
 #include "common.h"
 #include "ts_locale.h"
index fe79888bf3ec00b6fd09e0d1b7c6d634edc50c0e..5734881947e9b6a1309108783a0920b926b3e323 100644 (file)
@@ -1,9 +1,11 @@
 #ifndef __SPELL_H__
 #define __SPELL_H__
 
+#include "c.h"
+
 #include <sys/types.h>
+
 #include "regex/regex.h"
-#include "c.h"
 
 #include "regis.h"
 #include "dict.h"
index d38faa71a586c15ddaa6c8558a7c0e480a60ff7d..db7c2ef697cae49b79fd56e2780b33fe0ff75fdf 100644 (file)
  *             ExecInitSubPlan - initialize a subselect
  *             ExecEndSubPlan  - shut down a subselect
  */
-#include <math.h>
-
 #include "postgres.h"
 
+#include <math.h>
+
 #include "access/heapam.h"
 #include "executor/executor.h"
 #include "executor/nodeSubplan.h"
index c9aebcff05042c1ccf11f133426e6223eabf3c26..625abd96e669762107d9a5ade1d4d9867989c692 100644 (file)
@@ -20,7 +20,6 @@
 #if defined(HAVE_STRUCT_CMSGCRED) || defined(HAVE_STRUCT_FCRED) || defined(HAVE_STRUCT_SOCKCRED)
 #include <sys/uio.h>
 #include <sys/ucred.h>
-#include <errno.h>
 #endif
 #include <netinet/in.h>
 #include <arpa/inet.h>
index c495ad0dccd6128c38bacdc3eb8485638411b52a..d87c57fe6550e91da2bc5de3c6691fb3f2f76a1b 100644 (file)
@@ -66,7 +66,6 @@
 #include "postgres.h"
 
 #include <signal.h>
-#include <errno.h>
 #include <fcntl.h>
 #include <grp.h>
 #include <unistd.h>
index 645b2ee653eb3c2f45271c9f166c5ea122c76872..79e8b1f393f7f0da2f69f876eb05491912f33423 100644 (file)
@@ -69,7 +69,6 @@
 
 #include "postgres.h"
 
-#include <errno.h>
 #include <sys/param.h>
 #include <netinet/in.h>
 #include <arpa/inet.h>
index 3ace7fc39153b7b50795ac830aa884e2d081bad1..64aca56ee2869a0c1ddbc049c6ea32e138a98dcb 100644 (file)
@@ -6,7 +6,6 @@
 
 #include "postgres.h"
 
-#include <errno.h>
 #include "sys/ldr.h"
 #include <a.out.h>
 #include "ldfcn.h"
index 524c37fac08b531f73dc30d904ebce5c4bf26dba..3d8cb4f5282c6a233edcbbc2a0d9a01d1b68746d 100644 (file)
@@ -27,7 +27,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <unistd.h>
 
 #include "miscadmin.h"
index a6aaa3243662bb374497b7da6d21a9efb7ba749b..42d8fc950e902a15efc31cb4bb07b1f537fddca7 100644 (file)
@@ -17,7 +17,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <fcntl.h>
 #include <signal.h>
 #include <unistd.h>
index 76ce4954f860c96d73e134495fca4c03a3a44561..4ece86e0394941fe6f966de5754400f797364a87 100644 (file)
@@ -14,7 +14,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <signal.h>
 #include <unistd.h>
 #include <sys/file.h>
index 0f63a8a24b8a6d35abbe41a2fb73f52cf9a7e1b1..7f21f1db4060e0b880b99613a94acb68b8172830 100644 (file)
@@ -16,7 +16,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <signal.h>
 #include <unistd.h>
 #include <sys/file.h>
index bff318266d1f3fec6f8f9422403337c7c73e4f82..1755b7248f4c727f5c9d3d7a8aaf5684fd483bbd 100644 (file)
@@ -13,9 +13,6 @@
 
 #include "postgres.h"
 
-#include <stdio.h>
-#include <errno.h>
-
 static DWORD s_segsize = 0;
 
 /* Detach from a shared mem area based on its address */
index bb7ede97a2fb81476ad92ab14a86f9e35b77c175..6377f59139c4b66fd9a9f00d2297a3ab755a2b3b 100644 (file)
@@ -34,8 +34,6 @@
 
 #include "postgres.h"
 
-#include <errno.h>
-
 #include "storage/fd.h"
 #include "storage/buffile.h"
 
index 77e4eef36fad2885ba355ee58ca2318e21293437..370db3a76881590af1e06211201b35ac9898846c 100644 (file)
@@ -58,7 +58,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <limits.h>
 #include <math.h>
 #include <unistd.h>
index 1f7962aebe9c75c7f5f18db92baac28a901f6663..ec87b69e18aaf3bc60726443e5f27fc57a9b78c9 100644 (file)
@@ -19,7 +19,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <signal.h>
 #include <unistd.h>
 
index 423b19d222ad17759297cdb79fc804cb5265e0c7..64f0321b27cd1be1c9491c1257cfcc01aa5ddffe 100644 (file)
@@ -14,7 +14,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <unistd.h>
 #include <fcntl.h>
 #include <sys/file.h>
index cf2de3ca22f08cbf8ce738c81538a2894ec47091..d0441119df9ac806d5b9df25045719d511fe0ec4 100644 (file)
@@ -15,7 +15,6 @@
 #include "postgres.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <float.h>
 #include <limits.h>
 #include <math.h>
index 08247370ffddc7a9ad90bf4821a2eeece65a17fd..2b87a675fab23f6bb0933927ff135f2c0374497a 100644 (file)
@@ -53,7 +53,6 @@
 #include "postgres.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <float.h>
 #include <math.h>
 #include <limits.h>
index a385deeeec3f7a7f7607fc17795dbfb5a15c914a..7be72cd61ef193036ab39fd6839dfd0f929dbd2f 100644 (file)
@@ -25,7 +25,6 @@
 #include <float.h>
 #include <limits.h>
 #include <math.h>
-#include <errno.h>
 
 #include "catalog/pg_type.h"
 #include "libpq/pqformat.h"
index 7a97791c71444298d2c283191957bd0c817f3631..735c16a82a09ff2ac77f01d0b6039687b22df2b9 100644 (file)
 
 #include <unistd.h>
 #include <fcntl.h>
-#include <errno.h>
 
 #include "utils/pg_lzcompress.h"
 
index 6b83dbe2846b0a0546fd14d0db218d2593ba39ab..fe2ee2f44bfdaaed22797fcf150a9033bab320e2 100644 (file)
@@ -17,7 +17,6 @@
  */
 #include "postgres.h"
 
-#include <errno.h>
 #include <math.h>
 #include <limits.h>
 
index cbf8162951b58d30a9346c3cf35623fc7017be52..ff1e1e533cae93bb0391b6a6aeff9d150848a78e 100644 (file)
@@ -12,7 +12,6 @@
 #include "help.h"
 
 #include <signal.h>
-#include <errno.h>
 
 #ifndef WIN32
 #ifdef HAVE_PWD_H
index 45dd656de8ed6b173c10f24ed9044185f06c5517..6decc523ec5e0c03483cf0be6894f87a3907d642 100644 (file)
@@ -9,7 +9,6 @@
 #define MAINLOOP_H
 
 #include "postgres_fe.h"
-#include <stdio.h>
 
 int                    MainLoop(FILE *source);
 
index 94bbe0658f41652fe3d0fa4ef6972934169b7d25..1bbb0f56a6ceb9dbeaba276a65a8bb2fc38a3f89 100644 (file)
@@ -3,8 +3,6 @@
 #define POSTGRES_ECPG_INTERNAL
 #include "postgres_fe.h"
 
-#include <stdio.h>
-
 #include "ecpgerrno.h"
 #include "ecpgtype.h"
 #include "ecpglib.h"
index 723dba08463fd171bcdec6e17f9664f3cd9175fa..066d1f08daedf25cc790977ec6b80134f7b5a034 100644 (file)
@@ -16,7 +16,6 @@
 #define POSTGRES_ECPG_INTERNAL
 #include "postgres_fe.h"
 
-#include <stdio.h>
 #include <locale.h>
 
 #include "pg_type.h"
index 043987d6fbde7181a156495b5982b17c67bd22e0..d1ee370f9645d8fe2293ef90cf8fb6ec7f949d54 100644 (file)
@@ -21,7 +21,6 @@
 #include <ctype.h>
 #include <sys/types.h>
 #include <limits.h>
-#include <errno.h>
 
 #include "extern.h"
 
index c65a805e6bad591024f11a4e20a1d80eee93f6f6..840407de9e7c7a6151c79fa896abc4da917200e4 100644 (file)
@@ -30,7 +30,6 @@
 
 #include "postgres_fe.h"
 
-#include <errno.h>
 #include <signal.h>
 #include <time.h>
 
index 780db0f6e34e5df09f5f0cfd5749bb131779713e..8810080ad227332b74b828a1fb7586202ca04875 100644 (file)
@@ -14,7 +14,6 @@
  */
 #include "postgres_fe.h"
 
-#include <errno.h>
 #include <ctype.h>
 #include <fcntl.h>
 
index 69c34db482c0213f7ce17e2e51665f7cdacb0c1d..ca8640eab062bdb47e1354e52ac7bf60cbf6022a 100644 (file)
@@ -24,7 +24,6 @@
 #include "storage/fd.h"
 #include "tzfile.h"
 #include "utils/datetime.h"
-#include "utils/elog.h"
 #include "utils/guc.h"
 #include "utils/hsearch.h"