diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2006-05-30 22:12:16 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2006-05-30 22:12:16 +0000 |
| commit | a0ffab351e2dca12200e95c45f6edf5ddebe78b0 (patch) | |
| tree | 905fee345f116de536f72d8ff8507d093646d717 /contrib | |
| parent | e95703eac3199a389cfeace07545ee10430193a8 (diff) | |
| download | postgresql-a0ffab351e2dca12200e95c45f6edf5ddebe78b0.tar.gz | |
Magic blocks don't do us any good unless we use 'em ... so install one
in every shared library.
Diffstat (limited to 'contrib')
29 files changed, 75 insertions, 19 deletions
diff --git a/contrib/btree_gist/btree_gist.c b/contrib/btree_gist/btree_gist.c index a64a6cb7c1..c5c7bb88bb 100644 --- a/contrib/btree_gist/btree_gist.c +++ b/contrib/btree_gist/btree_gist.c @@ -1,5 +1,7 @@ #include "btree_gist.h" +PG_MODULE_MAGIC; + PG_FUNCTION_INFO_V1(gbt_decompress); PG_FUNCTION_INFO_V1(gbtreekey_in); PG_FUNCTION_INFO_V1(gbtreekey_out); diff --git a/contrib/chkpass/chkpass.c b/contrib/chkpass/chkpass.c index e20164eed2..04591bd154 100644 --- a/contrib/chkpass/chkpass.c +++ b/contrib/chkpass/chkpass.c @@ -4,7 +4,7 @@ * darcy@druid.net * http://www.druid.net/darcy/ * - * $PostgreSQL: pgsql/contrib/chkpass/chkpass.c,v 1.15 2006/03/19 22:22:55 neilc Exp $ + * $PostgreSQL: pgsql/contrib/chkpass/chkpass.c,v 1.16 2006/05/30 22:12:12 tgl Exp $ * best viewed with tabs set to 4 */ @@ -20,6 +20,8 @@ #include "fmgr.h" +PG_MODULE_MAGIC; + /* * This type encrypts it's input unless the first character is a colon. * The output is the encrypted form with a leading colon. The output diff --git a/contrib/cube/cube.c b/contrib/cube/cube.c index c6df246d25..944eee62b1 100644 --- a/contrib/cube/cube.c +++ b/contrib/cube/cube.c @@ -1,5 +1,5 @@ /****************************************************************************** - $PostgreSQL: pgsql/contrib/cube/cube.c,v 1.24 2006/03/11 04:38:28 momjian Exp $ + $PostgreSQL: pgsql/contrib/cube/cube.c,v 1.25 2006/05/30 22:12:12 tgl Exp $ This file contains routines that can be bound to a Postgres backend and called by the backend in the process of processing queries. The calling @@ -18,6 +18,8 @@ #include "cubedata.h" +PG_MODULE_MAGIC; + extern int cube_yyparse(); extern void cube_yyerror(const char *message); extern void cube_scanner_init(const char *str); diff --git a/contrib/dblink/dblink.c b/contrib/dblink/dblink.c index 42ffd6f3b6..e8b3018576 100644 --- a/contrib/dblink/dblink.c +++ b/contrib/dblink/dblink.c @@ -8,7 +8,7 @@ * Darko Prenosil <Darko.Prenosil@finteh.hr> * Shridhar Daithankar <shridhar_daithankar@persistent.co.in> * - * $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.54 2006/03/11 04:38:29 momjian Exp $ + * $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.55 2006/05/30 22:12:12 tgl Exp $ * Copyright (c) 2001-2006, PostgreSQL Global Development Group * ALL RIGHTS RESERVED; * @@ -61,6 +61,8 @@ #include "dblink.h" +PG_MODULE_MAGIC; + typedef struct remoteConn { PGconn *conn; /* Hold the remote connection */ diff --git a/contrib/dbmirror/pending.c b/contrib/dbmirror/pending.c index 3a405d1270..cfee9561ac 100644 --- a/contrib/dbmirror/pending.c +++ b/contrib/dbmirror/pending.c @@ -1,7 +1,7 @@ /**************************************************************************** * pending.c - * $Id: pending.c,v 1.24 2006/05/19 02:38:47 momjian Exp $ - * $PostgreSQL: pgsql/contrib/dbmirror/pending.c,v 1.24 2006/05/19 02:38:47 momjian Exp $ + * $Id: pending.c,v 1.25 2006/05/30 22:12:12 tgl Exp $ + * $PostgreSQL: pgsql/contrib/dbmirror/pending.c,v 1.25 2006/05/30 22:12:12 tgl Exp $ * * This file contains a trigger for Postgresql-7.x to record changes to tables * to a pending table for mirroring. @@ -38,6 +38,8 @@ #include "utils/lsyscache.h" #include "utils/array.h" +PG_MODULE_MAGIC; + enum FieldUsage { PRIMARY = 0, NONPRIMARY, ALL, NUM_FIELDUSAGE diff --git a/contrib/earthdistance/earthdistance.c b/contrib/earthdistance/earthdistance.c index d3032bde88..1f7baa3c30 100644 --- a/contrib/earthdistance/earthdistance.c +++ b/contrib/earthdistance/earthdistance.c @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/contrib/earthdistance/earthdistance.c,v 1.10 2006/03/11 04:38:29 momjian Exp $ */ +/* $PostgreSQL: pgsql/contrib/earthdistance/earthdistance.c,v 1.11 2006/05/30 22:12:12 tgl Exp $ */ #include "postgres.h" @@ -7,6 +7,8 @@ #include "utils/geo_decls.h" /* for Pt */ +PG_MODULE_MAGIC; + /* Earth's radius is in statute miles. */ const double EARTH_RADIUS = 3958.747716; const double TWO_PI = 2.0 * M_PI; diff --git a/contrib/fulltextindex/fti.c b/contrib/fulltextindex/fti.c index 938e7748c5..a0282ec95b 100644 --- a/contrib/fulltextindex/fti.c +++ b/contrib/fulltextindex/fti.c @@ -8,7 +8,7 @@ /* * Trigger function accepts variable number of arguments: * - * $PostgreSQL: pgsql/contrib/fulltextindex/fti.c,v 1.26 2006/03/11 04:38:29 momjian Exp $ + * $PostgreSQL: pgsql/contrib/fulltextindex/fti.c,v 1.27 2006/05/30 22:12:12 tgl Exp $ * * 1. relation in which to store the substrings * 2. fields to extract substrings from @@ -88,6 +88,8 @@ * that can build the final query automagically? */ +PG_MODULE_MAGIC; + #define MAX_FTI_QUERY_LENGTH 8192 extern Datum fti(PG_FUNCTION_ARGS); diff --git a/contrib/fuzzystrmatch/fuzzystrmatch.c b/contrib/fuzzystrmatch/fuzzystrmatch.c index 29bba52596..9b12c8f1fd 100644 --- a/contrib/fuzzystrmatch/fuzzystrmatch.c +++ b/contrib/fuzzystrmatch/fuzzystrmatch.c @@ -5,7 +5,7 @@ * * Joe Conway <mail@joeconway.com> * - * $PostgreSQL: pgsql/contrib/fuzzystrmatch/fuzzystrmatch.c,v 1.20 2006/03/19 22:22:56 neilc Exp $ + * $PostgreSQL: pgsql/contrib/fuzzystrmatch/fuzzystrmatch.c,v 1.21 2006/05/30 22:12:13 tgl Exp $ * Copyright (c) 2001-2006, PostgreSQL Global Development Group * ALL RIGHTS RESERVED; * @@ -45,6 +45,8 @@ #include "fuzzystrmatch.h" +PG_MODULE_MAGIC; + /* * Calculates Levenshtein Distance between two strings. * Uses simplest and fastest cost model only, i.e. assumes a cost of 1 for diff --git a/contrib/intagg/int_aggregate.c b/contrib/intagg/int_aggregate.c index d081278634..d75ce36106 100644 --- a/contrib/intagg/int_aggregate.c +++ b/contrib/intagg/int_aggregate.c @@ -5,7 +5,7 @@ * DMN Digital Music Network. * www.dmn.com * - * $PostgreSQL: pgsql/contrib/intagg/int_aggregate.c,v 1.23 2006/03/11 04:38:29 momjian Exp $ + * $PostgreSQL: pgsql/contrib/intagg/int_aggregate.c,v 1.24 2006/05/30 22:12:13 tgl Exp $ * * Copyright (C) Digital Music Network * December 20, 2001 @@ -34,6 +34,7 @@ #include "utils/memutils.h" #include "utils/lsyscache.h" +PG_MODULE_MAGIC; /* * This is actually a postgres version of a one dimensional array. diff --git a/contrib/intarray/_int_op.c b/contrib/intarray/_int_op.c index 036c357fb0..40650b6af8 100644 --- a/contrib/intarray/_int_op.c +++ b/contrib/intarray/_int_op.c @@ -2,6 +2,8 @@ #include "lib/stringinfo.h" +PG_MODULE_MAGIC; + PG_FUNCTION_INFO_V1(_int_different); PG_FUNCTION_INFO_V1(_int_same); PG_FUNCTION_INFO_V1(_int_contains); diff --git a/contrib/isbn_issn/isbn_issn.c b/contrib/isbn_issn/isbn_issn.c index ed8707e05f..7f84951c06 100644 --- a/contrib/isbn_issn/isbn_issn.c +++ b/contrib/isbn_issn/isbn_issn.c @@ -1,11 +1,15 @@ /* * PostgreSQL type definitions for ISBNs. * - * $PostgreSQL: pgsql/contrib/isbn_issn/isbn_issn.c,v 1.8 2006/03/01 06:30:31 neilc Exp $ + * $PostgreSQL: pgsql/contrib/isbn_issn/isbn_issn.c,v 1.9 2006/05/30 22:12:13 tgl Exp $ */ #include "postgres.h" +#include "fmgr.h" + + +PG_MODULE_MAGIC; /* * This is the internal storage format for ISBNs. diff --git a/contrib/lo/lo.c b/contrib/lo/lo.c index 8d6ba169a2..c5cf2cf75b 100644 --- a/contrib/lo/lo.c +++ b/contrib/lo/lo.c @@ -1,7 +1,7 @@ /* * PostgreSQL definitions for managed Large Objects. * - * $PostgreSQL: pgsql/contrib/lo/lo.c,v 1.15 2005/06/23 00:06:37 tgl Exp $ + * $PostgreSQL: pgsql/contrib/lo/lo.c,v 1.16 2006/05/30 22:12:13 tgl Exp $ * */ @@ -17,6 +17,7 @@ /* Required for triggers */ #include "commands/trigger.h" +PG_MODULE_MAGIC; #define atooid(x) ((Oid) strtoul((x), NULL, 10)) diff --git a/contrib/ltree/ltree_op.c b/contrib/ltree/ltree_op.c index 4a49e35ce8..86178d0a9e 100644 --- a/contrib/ltree/ltree_op.c +++ b/contrib/ltree/ltree_op.c @@ -1,7 +1,7 @@ /* * op function for ltree * Teodor Sigaev <teodor@stack.net> - * $PostgreSQL: pgsql/contrib/ltree/ltree_op.c,v 1.11 2006/04/27 18:24:35 tgl Exp $ + * $PostgreSQL: pgsql/contrib/ltree/ltree_op.c,v 1.12 2006/05/30 22:12:13 tgl Exp $ */ #include "ltree.h" @@ -12,6 +12,7 @@ #include "utils/selfuncs.h" #include "utils/syscache.h" +PG_MODULE_MAGIC; /* compare functions */ PG_FUNCTION_INFO_V1(ltree_cmp); diff --git a/contrib/pg_buffercache/pg_buffercache_pages.c b/contrib/pg_buffercache/pg_buffercache_pages.c index a0ae43f77d..a2811eb001 100644 --- a/contrib/pg_buffercache/pg_buffercache_pages.c +++ b/contrib/pg_buffercache/pg_buffercache_pages.c @@ -3,7 +3,7 @@ * pg_buffercache_pages.c * display some contents of the buffer cache * - * $PostgreSQL: pgsql/contrib/pg_buffercache/pg_buffercache_pages.c,v 1.6 2005/10/15 02:49:05 momjian Exp $ + * $PostgreSQL: pgsql/contrib/pg_buffercache/pg_buffercache_pages.c,v 1.7 2006/05/30 22:12:13 tgl Exp $ *------------------------------------------------------------------------- */ #include "postgres.h" @@ -21,6 +21,8 @@ extern DLLIMPORT BufferDesc *BufferDescriptors; extern DLLIMPORT volatile uint32 InterruptHoldoffCount; #endif +PG_MODULE_MAGIC; + Datum pg_buffercache_pages(PG_FUNCTION_ARGS); diff --git a/contrib/pg_freespacemap/pg_freespacemap.c b/contrib/pg_freespacemap/pg_freespacemap.c index 5ee85fdddd..0ab99482ff 100644 --- a/contrib/pg_freespacemap/pg_freespacemap.c +++ b/contrib/pg_freespacemap/pg_freespacemap.c @@ -3,7 +3,7 @@ * pg_freespacemap.c * display some contents of the free space relation and page maps. * - * $PostgreSQL: pgsql/contrib/pg_freespacemap/pg_freespacemap.c,v 1.5 2006/05/04 20:39:34 tgl Exp $ + * $PostgreSQL: pgsql/contrib/pg_freespacemap/pg_freespacemap.c,v 1.6 2006/05/30 22:12:13 tgl Exp $ *------------------------------------------------------------------------- */ #include "postgres.h" @@ -24,6 +24,8 @@ extern DLLIMPORT int MaxFSMRelations; extern DLLIMPORT volatile uint32 InterruptHoldoffCount; #endif +PG_MODULE_MAGIC; + Datum pg_freespacemap_pages(PG_FUNCTION_ARGS); Datum pg_freespacemap_relations(PG_FUNCTION_ARGS); diff --git a/contrib/pg_trgm/trgm_op.c b/contrib/pg_trgm/trgm_op.c index b7043c1b8c..2869033932 100644 --- a/contrib/pg_trgm/trgm_op.c +++ b/contrib/pg_trgm/trgm_op.c @@ -3,6 +3,8 @@ #include "utils/array.h" #include "catalog/pg_type.h" +PG_MODULE_MAGIC; + float4 trgm_limit = 0.3; PG_FUNCTION_INFO_V1(set_limit); diff --git a/contrib/pgcrypto/pgcrypto.c b/contrib/pgcrypto/pgcrypto.c index cc3814aacd..6196a1b4d6 100644 --- a/contrib/pgcrypto/pgcrypto.c +++ b/contrib/pgcrypto/pgcrypto.c @@ -26,7 +26,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $PostgreSQL: pgsql/contrib/pgcrypto/pgcrypto.c,v 1.20 2005/10/15 02:49:06 momjian Exp $ + * $PostgreSQL: pgsql/contrib/pgcrypto/pgcrypto.c,v 1.21 2006/05/30 22:12:13 tgl Exp $ */ #include "postgres.h" @@ -40,6 +40,8 @@ #include "px-crypt.h" #include "pgcrypto.h" +PG_MODULE_MAGIC; + /* private stuff */ typedef int (*PFN) (const char *name, void **res); diff --git a/contrib/pgrowlocks/pgrowlocks.c b/contrib/pgrowlocks/pgrowlocks.c index 1253f7c51a..d504601ae0 100644 --- a/contrib/pgrowlocks/pgrowlocks.c +++ b/contrib/pgrowlocks/pgrowlocks.c @@ -1,5 +1,5 @@ /* - * $PostgreSQL: pgsql/contrib/pgrowlocks/pgrowlocks.c,v 1.2 2006/04/25 00:40:54 ishii Exp $ + * $PostgreSQL: pgsql/contrib/pgrowlocks/pgrowlocks.c,v 1.3 2006/05/30 22:12:13 tgl Exp $ * * Copyright (c) 2005-2006 Tatsuo Ishii * @@ -37,6 +37,8 @@ #include "storage/procarray.h" #endif +PG_MODULE_MAGIC; + PG_FUNCTION_INFO_V1(pgrowlocks); extern Datum pgrowlocks(PG_FUNCTION_ARGS); diff --git a/contrib/pgstattuple/pgstattuple.c b/contrib/pgstattuple/pgstattuple.c index cb79fadedb..d4c2c6cdbd 100644 --- a/contrib/pgstattuple/pgstattuple.c +++ b/contrib/pgstattuple/pgstattuple.c @@ -1,5 +1,5 @@ /* - * $PostgreSQL: pgsql/contrib/pgstattuple/pgstattuple.c,v 1.20 2005/10/15 02:49:06 momjian Exp $ + * $PostgreSQL: pgsql/contrib/pgstattuple/pgstattuple.c,v 1.21 2006/05/30 22:12:13 tgl Exp $ * * Copyright (c) 2001,2002 Tatsuo Ishii * @@ -32,6 +32,8 @@ #include "utils/builtins.h" +PG_MODULE_MAGIC; + PG_FUNCTION_INFO_V1(pgstattuple); PG_FUNCTION_INFO_V1(pgstattuplebyid); diff --git a/contrib/seg/seg.c b/contrib/seg/seg.c index 0a694a52dd..47ca1b614a 100644 --- a/contrib/seg/seg.c +++ b/contrib/seg/seg.c @@ -19,6 +19,8 @@ #define GIST_QUERY_DEBUG */ +PG_MODULE_MAGIC; + extern int seg_yyparse(); extern void seg_yyerror(const char *message); extern void seg_scanner_init(const char *str); diff --git a/contrib/spi/autoinc.c b/contrib/spi/autoinc.c index bad7c52735..5904f1f431 100644 --- a/contrib/spi/autoinc.c +++ b/contrib/spi/autoinc.c @@ -3,6 +3,8 @@ #include "commands/trigger.h" /* -"- and triggers */ #include "commands/sequence.h" /* for nextval() */ +PG_MODULE_MAGIC; + extern Datum autoinc(PG_FUNCTION_ARGS); PG_FUNCTION_INFO_V1(autoinc); diff --git a/contrib/spi/insert_username.c b/contrib/spi/insert_username.c index 06de9632bd..73ed17cc1c 100644 --- a/contrib/spi/insert_username.c +++ b/contrib/spi/insert_username.c @@ -1,7 +1,7 @@ /* * insert_username.c * $Modified: Thu Oct 16 08:13:42 1997 by brook $ - * $PostgreSQL: pgsql/contrib/spi/insert_username.c,v 1.13 2006/03/11 04:38:30 momjian Exp $ + * $PostgreSQL: pgsql/contrib/spi/insert_username.c,v 1.14 2006/05/30 22:12:13 tgl Exp $ * * insert user name in response to a trigger * usage: insert_username (column_name) @@ -11,6 +11,8 @@ #include "commands/trigger.h" /* -"- and triggers */ #include "miscadmin.h" /* for GetUserName() */ +PG_MODULE_MAGIC; + extern Datum insert_username(PG_FUNCTION_ARGS); PG_FUNCTION_INFO_V1(insert_username); diff --git a/contrib/spi/moddatetime.c b/contrib/spi/moddatetime.c index 43ad810793..ca4e6c0f33 100644 --- a/contrib/spi/moddatetime.c +++ b/contrib/spi/moddatetime.c @@ -1,7 +1,7 @@ /* moddatetime.c -$PostgreSQL: pgsql/contrib/spi/moddatetime.c,v 1.12 2006/03/11 04:38:30 momjian Exp $ +$PostgreSQL: pgsql/contrib/spi/moddatetime.c,v 1.13 2006/05/30 22:12:13 tgl Exp $ What is this? It is a function to be called from a trigger for the purpose of updating @@ -17,6 +17,8 @@ OH, me, I'm Terry Mackintosh <terry@terrym.com> #include "executor/spi.h" /* this is what you need to work with SPI */ #include "commands/trigger.h" /* -"- and triggers */ +PG_MODULE_MAGIC; + extern Datum moddatetime(PG_FUNCTION_ARGS); PG_FUNCTION_INFO_V1(moddatetime); diff --git a/contrib/spi/refint.c b/contrib/spi/refint.c index 8163f8ebaf..a060f9effa 100644 --- a/contrib/spi/refint.c +++ b/contrib/spi/refint.c @@ -8,6 +8,8 @@ #include <ctype.h> +PG_MODULE_MAGIC; + extern Datum check_primary_key(PG_FUNCTION_ARGS); extern Datum check_foreign_key(PG_FUNCTION_ARGS); diff --git a/contrib/spi/timetravel.c b/contrib/spi/timetravel.c index 84a1153854..026e4ac813 100644 --- a/contrib/spi/timetravel.c +++ b/contrib/spi/timetravel.c @@ -14,6 +14,8 @@ #define ABSTIMEOID 702 /* it should be in pg_type.h */ +PG_MODULE_MAGIC; + /* AbsoluteTime currabstime(void); */ Datum timetravel(PG_FUNCTION_ARGS); Datum set_timetravel(PG_FUNCTION_ARGS); diff --git a/contrib/tablefunc/tablefunc.c b/contrib/tablefunc/tablefunc.c index 334bd62b24..f5f751e72f 100644 --- a/contrib/tablefunc/tablefunc.c +++ b/contrib/tablefunc/tablefunc.c @@ -42,6 +42,8 @@ #include "tablefunc.h" +PG_MODULE_MAGIC; + static int load_categories_hash(char *cats_sql, MemoryContext per_query_ctx); static Tuplestorestate *get_crosstab_tuplestore(char *sql, int num_categories, diff --git a/contrib/tsearch2/ts_cfg.c b/contrib/tsearch2/ts_cfg.c index 3bc39a8737..a71cf97e59 100644 --- a/contrib/tsearch2/ts_cfg.c +++ b/contrib/tsearch2/ts_cfg.c @@ -20,6 +20,8 @@ #include "common.h" #include "tsvector.h" +PG_MODULE_MAGIC; + #define IGNORE_LONGLEXEME 1 /*********top interface**********/ diff --git a/contrib/userlock/user_locks.c b/contrib/userlock/user_locks.c index 53c48bf0a7..c27dc253d8 100644 --- a/contrib/userlock/user_locks.c +++ b/contrib/userlock/user_locks.c @@ -17,6 +17,7 @@ #include "user_locks.h" +PG_MODULE_MAGIC; #define SET_LOCKTAG_USERLOCK(locktag,id1,id2) \ ((locktag).locktag_field1 = MyDatabaseId, \ diff --git a/contrib/xml2/xslt_proc.c b/contrib/xml2/xslt_proc.c index 433030ead9..404aa2a790 100644 --- a/contrib/xml2/xslt_proc.c +++ b/contrib/xml2/xslt_proc.c @@ -21,6 +21,8 @@ #include <libxslt/xsltutils.h> +PG_MODULE_MAGIC; + /* declarations to come from xpath.c */ extern void elog_error(int level, char *explain, int force); |
