diff --git a/.gitignore b/.gitignore index 20e282d..a63d664 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,3 @@ SOURCES/postgresql-8.4.20.tar.bz2 -SOURCES/postgresql-9.2.7-US.pdf -SOURCES/postgresql-9.2.7.tar.bz2 +SOURCES/postgresql-9.2.10-US.pdf +SOURCES/postgresql-9.2.10.tar.bz2 diff --git a/.postgresql.metadata b/.postgresql.metadata index 2296369..d3414d8 100644 --- a/.postgresql.metadata +++ b/.postgresql.metadata @@ -1,3 +1,3 @@ bad68fc70f90a28212459e5347c32ebbdfcf2c8e SOURCES/postgresql-8.4.20.tar.bz2 -d420a9eb3871aa71ac2d9e0abeccb0b9de1300b1 SOURCES/postgresql-9.2.7-US.pdf -20b6a83e7ba4bbaa1544bfdf4622ccd205bfc509 SOURCES/postgresql-9.2.7.tar.bz2 +b08cdf0956d7612c0cbc9d92872a6f2102f85c17 SOURCES/postgresql-9.2.10-US.pdf +3c82fc1d37ae10063b15caef39216616252de0a0 SOURCES/postgresql-9.2.10.tar.bz2 diff --git a/SOURCES/postgresql-multi-sockets.patch b/SOURCES/postgresql-multi-sockets.patch index d396174..f6b9379 100644 --- a/SOURCES/postgresql-multi-sockets.patch +++ b/SOURCES/postgresql-multi-sockets.patch @@ -10,11 +10,11 @@ package don't include the necessary documentation tools. Those diff hunks *must be at the end* so that those files are newer than the master doc files. - -diff -Naur -r postgresql-9.2.5.orig/contrib/pg_upgrade/server.c postgresql-9.2.5/contrib/pg_upgrade/server.c ---- postgresql-9.2.5.orig/contrib/pg_upgrade/server.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/contrib/pg_upgrade/server.c 2013-10-21 17:51:03.057675930 +0200 -@@ -197,7 +197,8 @@ +diff --git a/contrib/pg_upgrade/server.c b/contrib/pg_upgrade/server.c +index 0940e00..c5ecb84 100644 +--- a/contrib/pg_upgrade/server.c ++++ b/contrib/pg_upgrade/server.c +@@ -197,7 +197,8 @@ start_postmaster(ClusterInfo *cluster) snprintf(socket_string + strlen(socket_string), sizeof(socket_string) - strlen(socket_string), " -c %s='%s'", @@ -24,10 +24,11 @@ diff -Naur -r postgresql-9.2.5.orig/contrib/pg_upgrade/server.c postgresql-9.2.5 "unix_socket_directory" : "unix_socket_directories", cluster->sockdir); #endif -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/client-auth.sgml postgresql-9.2.5/doc/src/sgml/client-auth.sgml ---- postgresql-9.2.5.orig/doc/src/sgml/client-auth.sgml 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/client-auth.sgml 2013-10-21 17:51:03.058675937 +0200 -@@ -838,7 +838,7 @@ +diff --git a/doc/src/sgml/client-auth.sgml b/doc/src/sgml/client-auth.sgml +index b9664cb..94e166d 100644 +--- a/doc/src/sgml/client-auth.sgml ++++ b/doc/src/sgml/client-auth.sgml +@@ -838,7 +838,7 @@ omicron bryanh guest1 unix_socket_permissions (and possibly unix_socket_group) configuration parameters as described in . Or you @@ -36,10 +37,11 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/client-auth.sgml postgresql-9.2 configuration parameter to place the socket file in a suitably restricted directory. -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/config.sgml postgresql-9.2.5/doc/src/sgml/config.sgml ---- postgresql-9.2.5.orig/doc/src/sgml/config.sgml 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/config.sgml 2013-10-21 17:51:03.059675944 +0200 -@@ -453,17 +453,24 @@ +diff --git a/doc/src/sgml/config.sgml b/doc/src/sgml/config.sgml +index 51d7da9..cb5c5d2 100644 +--- a/doc/src/sgml/config.sgml ++++ b/doc/src/sgml/config.sgml +@@ -453,17 +453,24 @@ SET ENABLE_SEQSCAN TO OFF; @@ -71,7 +73,7 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/config.sgml postgresql-9.2.5/do This parameter can only be set at server start. -@@ -472,8 +479,8 @@ +@@ -472,8 +479,8 @@ SET ENABLE_SEQSCAN TO OFF; .s.PGSQL.nnnn where nnnn is the server's port number, an ordinary file named .s.PGSQL.nnnn.lock will be @@ -82,7 +84,7 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/config.sgml postgresql-9.2.5/do -@@ -490,8 +497,8 @@ +@@ -490,8 +497,8 @@ SET ENABLE_SEQSCAN TO OFF; @@ -93,7 +95,7 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/config.sgml postgresql-9.2.5/do server.) In combination with the parameter unix_socket_permissions this can be used as an additional access control mechanism for Unix-domain connections. -@@ -514,7 +521,7 @@ +@@ -514,7 +521,7 @@ SET ENABLE_SEQSCAN TO OFF; @@ -102,7 +104,7 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/config.sgml postgresql-9.2.5/do sockets use the usual Unix file system permission set. The parameter value is expected to be a numeric mode specified in the format accepted by the -@@ -6618,7 +6625,7 @@ +@@ -6624,7 +6631,7 @@ LOG: CleanUpLock: deleting: lock(0xb7acd844) id(24688,24696,0,0,0,1) @@ -111,10 +113,11 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/config.sgml postgresql-9.2.5/do -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/html/app-postgres.html postgresql-9.2.5/doc/src/sgml/html/app-postgres.html ---- postgresql-9.2.5.orig/doc/src/sgml/html/app-postgres.html 2013-10-08 05:47:38.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/html/app-postgres.html 2013-10-21 17:51:03.060675950 +0200 -@@ -574,11 +574,19 @@ +diff --git a/doc/src/sgml/html/app-postgres.html b/doc/src/sgml/html/app-postgres.html +index b1f4e31..b6359a8 100644 +--- a/doc/src/sgml/html/app-postgres.html ++++ b/doc/src/sgml/html/app-postgres.html +@@ -574,11 +574,19 @@ CLASS="REPLACEABLE" CLASS="COMMAND" >postgres is to listen for @@ -136,10 +139,11 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/html/app-postgres.html postgres

. Or you could set the configuration parameter to place the socket file in a suitably restricted directory. -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/html/bookindex.html postgresql-9.2.5/doc/src/sgml/html/bookindex.html ---- postgresql-9.2.5.orig/doc/src/sgml/html/bookindex.html 2013-10-08 05:48:15.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/html/bookindex.html 2013-10-21 17:51:03.062675963 +0200 -@@ -17250,7 +17250,7 @@ +diff --git a/doc/src/sgml/html/bookindex.html b/doc/src/sgml/html/bookindex.html +index 5e25f95..1562ffe 100644 +--- a/doc/src/sgml/html/bookindex.html ++++ b/doc/src/sgml/html/bookindex.html +@@ -17250,7 +17250,7 @@ HREF="xfunc-c.html#DFUNC" >
Connection Settingslocal connections is to use a Unix domain socket directory () that has write permission only for a trusted local user. This prevents a malicious user from creating their own socket file in that directory. If you are concerned that -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/html/runtime-config-connection.html postgresql-9.2.5/doc/src/sgml/html/runtime-config-connection.html ---- postgresql-9.2.5.orig/doc/src/sgml/html/runtime-config-connection.html 2013-10-08 05:47:21.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/html/runtime-config-connection.html 2013-10-21 17:51:03.063675969 +0200 -@@ -274,24 +274,31 @@ +diff --git a/doc/src/sgml/html/runtime-config-connection.html b/doc/src/sgml/html/runtime-config-connection.html +index 74f096e..0ba6987 100644 +--- a/doc/src/sgml/html/runtime-config-connection.html ++++ b/doc/src/sgml/html/runtime-config-connection.html +@@ -274,24 +274,31 @@ CLASS="VARNAME" >

.lock will be @@ -231,7 +238,7 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/html/runtime-config-connection.

This parameter is irrelevant on Windows, which does not have -@@ -344,8 +351,8 @@ +@@ -344,8 +351,8 @@ CLASS="TYPE" >)

)

x Specifies the directory of the Unix-domain socket on which postgres is to listen for @@ -299,10 +309,11 @@ diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/ref/postgres-ref.sgml postgresq -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/runtime.sgml postgresql-9.2.5/doc/src/sgml/runtime.sgml ---- postgresql-9.2.5.orig/doc/src/sgml/runtime.sgml 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/runtime.sgml 2013-10-21 17:51:03.064675976 +0200 -@@ -1798,7 +1798,7 @@ +diff --git a/doc/src/sgml/runtime.sgml b/doc/src/sgml/runtime.sgml +index cfd3532..e6c9eaa 100644 +--- a/doc/src/sgml/runtime.sgml ++++ b/doc/src/sgml/runtime.sgml +@@ -1800,7 +1800,7 @@ pg_dumpall -p 5432 | psql -d postgres -p 5433 The simplest way to prevent spoofing for local connections is to use a Unix domain socket directory (/tmp for the -diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/src/backend/libpq/pqcomm.c ---- postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/libpq/pqcomm.c 2013-10-21 17:51:03.065675983 +0200 +diff --git a/src/backend/libpq/pqcomm.c b/src/backend/libpq/pqcomm.c +index aeeffd7..b7e0d09 100644 +--- a/src/backend/libpq/pqcomm.c ++++ b/src/backend/libpq/pqcomm.c @@ -42,7 +42,7 @@ * StreamServerPort - Open postmaster's server port * StreamConnection - Create new connection with client @@ -323,7 +335,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ * pq_init - initialize libpq at backend startup * pq_comm_reset - reset libpq during error recovery * pq_close - shutdown libpq at backend exit -@@ -103,8 +103,8 @@ +@@ -103,8 +103,8 @@ int Unix_socket_permissions; char *Unix_socket_group; @@ -334,7 +346,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ /* -@@ -140,8 +140,8 @@ +@@ -141,8 +141,8 @@ static int internal_flush(void); static void pq_set_nonblocking(bool nonblocking); #ifdef HAVE_UNIX_SOCKETS @@ -345,7 +357,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ #endif /* HAVE_UNIX_SOCKETS */ -@@ -234,29 +234,43 @@ +@@ -236,29 +236,43 @@ pq_close(int code, Datum arg) /* StreamDoUnlink() * Shutdown routine for backend connection @@ -395,7 +407,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ pgsocket ListenSocket[], int MaxListen) { pgsocket fd; -@@ -273,6 +287,9 @@ +@@ -275,6 +289,9 @@ StreamServerPort(int family, char *hostName, unsigned short portNumber, int listen_index = 0; int added = 0; @@ -405,7 +417,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ #if !defined(WIN32) || defined(IPV6_V6ONLY) int one = 1; #endif -@@ -286,10 +303,22 @@ +@@ -288,10 +305,22 @@ StreamServerPort(int family, char *hostName, unsigned short portNumber, #ifdef HAVE_UNIX_SOCKETS if (family == AF_UNIX) { @@ -422,16 +434,16 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ + (errmsg("Unix-domain socket path \"%s\" is too long (maximum %d bytes)", + unixSocketPath, + (int) (UNIXSOCK_PATH_BUFLEN - 1)))); -+ return STATUS_ERROR; -+ } -+ if (Lock_AF_UNIX(unixSocketDir, unixSocketPath) != STATUS_OK) return STATUS_ERROR; - service = sock_path; ++ } ++ if (Lock_AF_UNIX(unixSocketDir, unixSocketPath) != STATUS_OK) ++ return STATUS_ERROR; + service = unixSocketPath; } else #endif /* HAVE_UNIX_SOCKETS */ -@@ -432,7 +461,7 @@ +@@ -434,7 +463,7 @@ StreamServerPort(int family, char *hostName, unsigned short portNumber, (IS_AF_UNIX(addr->ai_family)) ? errhint("Is another postmaster already running on port %d?" " If not, remove socket file \"%s\" and retry.", @@ -440,7 +452,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ errhint("Is another postmaster already running on port %d?" " If not, wait a few seconds and retry.", (int) portNumber))); -@@ -443,7 +472,7 @@ +@@ -445,7 +474,7 @@ StreamServerPort(int family, char *hostName, unsigned short portNumber, #ifdef HAVE_UNIX_SOCKETS if (addr->ai_family == AF_UNIX) { @@ -449,7 +461,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ { closesocket(fd); break; -@@ -490,18 +519,8 @@ +@@ -492,18 +521,8 @@ StreamServerPort(int family, char *hostName, unsigned short portNumber, * Lock_AF_UNIX -- configure unix socket file path */ static int @@ -469,7 +481,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ /* * Grab an interlock file associated with the socket file. * -@@ -510,13 +529,23 @@ +@@ -512,13 +531,23 @@ Lock_AF_UNIX(unsigned short portNumber, char *unixSocketName) * more portable, and second, it lets us remove any pre-existing socket * file without race conditions. */ @@ -495,7 +507,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ return STATUS_OK; } -@@ -526,11 +555,8 @@ +@@ -528,11 +557,8 @@ Lock_AF_UNIX(unsigned short portNumber, char *unixSocketName) * Setup_AF_UNIX -- configure unix socket permissions */ static int @@ -508,7 +520,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ /* * Fix socket ownership/permission if requested. Note we must do this * before we listen() to avoid a window where unwanted connections could -@@ -712,20 +738,24 @@ +@@ -714,20 +740,24 @@ StreamClose(pgsocket sock) } /* @@ -539,10 +551,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/libpq/pqcomm.c postgresql-9.2.5/ /* * utime() is POSIX standard, utimes() is a common alternative. If we * have neither, there's no way to affect the mod or access time of -diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgresql-9.2.5/src/backend/postmaster/postmaster.c ---- postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/postmaster/postmaster.c 2013-10-21 17:51:03.066675990 +0200 -@@ -156,7 +156,9 @@ +diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c +index 07aca31..e84a18c 100644 +--- a/src/backend/postmaster/postmaster.c ++++ b/src/backend/postmaster/postmaster.c +@@ -160,7 +160,9 @@ static Backend *ShmemBackendArray; /* The socket number we are listening for connections on */ int PostPortNumber; @@ -553,7 +566,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres char *ListenAddresses; /* -@@ -608,7 +610,7 @@ +@@ -636,7 +638,7 @@ PostmasterMain(int argc, char *argv[]) break; case 'k': @@ -562,7 +575,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres break; case 'l': -@@ -852,7 +854,7 @@ +@@ -880,7 +882,7 @@ PostmasterMain(int argc, char *argv[]) /* Need a modifiable copy of ListenAddresses */ rawstring = pstrdup(ListenAddresses); @@ -571,7 +584,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres if (!SplitIdentifierString(rawstring, ',', &elemlist)) { /* syntax error in list */ -@@ -868,12 +870,12 @@ +@@ -896,12 +898,12 @@ PostmasterMain(int argc, char *argv[]) if (strcmp(curhost, "*") == 0) status = StreamServerPort(AF_UNSPEC, NULL, (unsigned short) PostPortNumber, @@ -586,7 +599,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres ListenSocket, MAXLISTEN); if (status == STATUS_OK) -@@ -892,7 +894,7 @@ +@@ -920,7 +922,7 @@ PostmasterMain(int argc, char *argv[]) curhost))); } @@ -595,7 +608,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres ereport(FATAL, (errmsg("could not create any TCP/IP sockets"))); -@@ -939,13 +941,54 @@ +@@ -967,13 +969,54 @@ PostmasterMain(int argc, char *argv[]) #endif #ifdef HAVE_UNIX_SOCKETS @@ -657,7 +670,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres #endif /* -@@ -1435,15 +1478,15 @@ +@@ -1452,15 +1495,15 @@ ServerLoop(void) } /* @@ -675,11 +688,12 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/postmaster/postmaster.c postgres + TouchSocketLockFiles(); last_touch_time = now; } - } -diff -Naur -r postgresql-9.2.5.orig/src/backend/tcop/postgres.c postgresql-9.2.5/src/backend/tcop/postgres.c ---- postgresql-9.2.5.orig/src/backend/tcop/postgres.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/tcop/postgres.c 2013-10-21 17:51:03.066675990 +0200 -@@ -3344,7 +3344,7 @@ + +diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c +index 39017ff..318ac38 100644 +--- a/src/backend/tcop/postgres.c ++++ b/src/backend/tcop/postgres.c +@@ -3393,7 +3393,7 @@ process_postgres_switches(int argc, char *argv[], GucContext ctx, break; case 'k': @@ -688,10 +702,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/tcop/postgres.c postgresql-9.2.5 break; case 'l': -diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/adt/varlena.c postgresql-9.2.5/src/backend/utils/adt/varlena.c ---- postgresql-9.2.5.orig/src/backend/utils/adt/varlena.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/utils/adt/varlena.c 2013-10-21 17:51:03.067675996 +0200 -@@ -2446,6 +2446,119 @@ +diff --git a/src/backend/utils/adt/varlena.c b/src/backend/utils/adt/varlena.c +index d4abfe3..e8217ac 100644 +--- a/src/backend/utils/adt/varlena.c ++++ b/src/backend/utils/adt/varlena.c +@@ -2446,6 +2446,119 @@ SplitIdentifierString(char *rawstring, char separator, } @@ -811,9 +826,10 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/adt/varlena.c postgresql-9 /***************************************************************************** * Comparison Functions used for bytea * -diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql-9.2.5/src/backend/utils/init/miscinit.c ---- postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/utils/init/miscinit.c 2013-10-21 17:51:03.067675996 +0200 +diff --git a/src/backend/utils/init/miscinit.c b/src/backend/utils/init/miscinit.c +index f994af6..db5303c 100644 +--- a/src/backend/utils/init/miscinit.c ++++ b/src/backend/utils/init/miscinit.c @@ -49,8 +49,8 @@ ProcessingMode Mode = InitProcessing; @@ -825,7 +841,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql /* ---------------------------------------------------------------- -@@ -640,32 +640,35 @@ +@@ -640,32 +640,35 @@ GetUserNameFromId(Oid roleid) */ /* @@ -871,7 +887,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql bool isDDLock, const char *refName) { int fd; -@@ -891,12 +894,7 @@ +@@ -891,12 +894,7 @@ CreateLockFile(const char *filename, bool amPostmaster, DataDir, (long) MyStartTime, PostPortNumber, @@ -885,7 +901,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql /* * In a standalone backend, the next line (LOCK_FILE_LINE_LISTEN_ADDR) -@@ -941,9 +939,14 @@ +@@ -941,9 +939,14 @@ CreateLockFile(const char *filename, bool amPostmaster, } /* @@ -902,7 +918,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql } /* -@@ -952,41 +955,50 @@ +@@ -952,41 +955,50 @@ CreateLockFile(const char *filename, bool amPostmaster, * When this is called, we must have already switched the working * directory to DataDir, so we can just use a relative path. This * helps ensure that we are locking the directory we should be. @@ -964,7 +980,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql /* * utime() is POSIX standard, utimes() is a common alternative; if we * have neither, fall back to actually reading the file (which only -@@ -1018,8 +1030,10 @@ +@@ -1018,8 +1030,10 @@ TouchSocketLockFile(void) * Add (or replace) a line in the data directory lock file. * The given string should not include a trailing newline. * @@ -977,7 +993,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql */ void AddToDataDirLockFile(int target_line, const char *str) -@@ -1027,8 +1041,10 @@ +@@ -1027,8 +1041,10 @@ AddToDataDirLockFile(int target_line, const char *str) int fd; int len; int lineno; @@ -990,7 +1006,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql fd = open(DIRECTORY_LOCK_FILE, O_RDWR | PG_BINARY, 0); if (fd < 0) -@@ -1039,7 +1055,7 @@ +@@ -1039,7 +1055,7 @@ AddToDataDirLockFile(int target_line, const char *str) DIRECTORY_LOCK_FILE))); return; } @@ -999,7 +1015,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql if (len < 0) { ereport(LOG, -@@ -1049,37 +1065,51 @@ +@@ -1049,37 +1065,51 @@ AddToDataDirLockFile(int target_line, const char *str) close(fd); return; } @@ -1059,10 +1075,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/init/miscinit.c postgresql { /* if write didn't set errno, assume problem is no disk space */ if (errno == 0) -diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/misc/guc.c postgresql-9.2.5/src/backend/utils/misc/guc.c ---- postgresql-9.2.5.orig/src/backend/utils/misc/guc.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/utils/misc/guc.c 2013-10-21 17:51:03.069676008 +0200 -@@ -2894,14 +2894,18 @@ +diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c +index e5ee0f8..1428cb6 100644 +--- a/src/backend/utils/misc/guc.c ++++ b/src/backend/utils/misc/guc.c +@@ -2894,14 +2894,18 @@ static struct config_string ConfigureNamesString[] = }, { @@ -1085,10 +1102,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/misc/guc.c postgresql-9.2. }, { -diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/misc/postgresql.conf.sample postgresql-9.2.5/src/backend/utils/misc/postgresql.conf.sample ---- postgresql-9.2.5.orig/src/backend/utils/misc/postgresql.conf.sample 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/backend/utils/misc/postgresql.conf.sample 2013-10-21 17:51:03.069676008 +0200 -@@ -65,7 +65,8 @@ +diff --git a/src/backend/utils/misc/postgresql.conf.sample b/src/backend/utils/misc/postgresql.conf.sample +index 013a91a..c0ab61c 100644 +--- a/src/backend/utils/misc/postgresql.conf.sample ++++ b/src/backend/utils/misc/postgresql.conf.sample +@@ -67,7 +67,8 @@ # Note: Increasing max_connections costs ~400 bytes of shared memory per # connection slot, plus lock space (see max_locks_per_transaction). #superuser_reserved_connections = 3 # (change requires restart) @@ -1098,10 +1116,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/backend/utils/misc/postgresql.conf.sampl #unix_socket_group = '' # (change requires restart) #unix_socket_permissions = 0777 # begin with 0 to use octal notation # (change requires restart) -diff -Naur -r postgresql-9.2.5.orig/src/bin/initdb/initdb.c postgresql-9.2.5/src/bin/initdb/initdb.c ---- postgresql-9.2.5.orig/src/bin/initdb/initdb.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/bin/initdb/initdb.c 2013-10-21 17:51:03.070676015 +0200 -@@ -991,7 +991,7 @@ +diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c +index 23fa468..452ac0b 100644 +--- a/src/bin/initdb/initdb.c ++++ b/src/bin/initdb/initdb.c +@@ -991,7 +991,7 @@ static void setup_config(void) { char **conflines; @@ -1110,7 +1129,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/bin/initdb/initdb.c postgresql-9.2.5/src char path[MAXPGPATH]; const char *default_timezone; -@@ -1013,6 +1013,15 @@ +@@ -1013,6 +1013,15 @@ setup_config(void) n_buffers * (BLCKSZ / 1024)); conflines = replace_token(conflines, "#shared_buffers = 32MB", repltok); @@ -1126,10 +1145,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/bin/initdb/initdb.c postgresql-9.2.5/src #if DEF_PGPORT != 5432 snprintf(repltok, sizeof(repltok), "#port = %d", DEF_PGPORT); conflines = replace_token(conflines, "#port = 5432", repltok); -diff -Naur -r postgresql-9.2.5.orig/src/bin/pg_ctl/pg_ctl.c postgresql-9.2.5/src/bin/pg_ctl/pg_ctl.c ---- postgresql-9.2.5.orig/src/bin/pg_ctl/pg_ctl.c 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/bin/pg_ctl/pg_ctl.c 2013-10-21 17:51:03.070676015 +0200 -@@ -559,7 +559,7 @@ +diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c +index 66ef6bd..b815ef2 100644 +--- a/src/bin/pg_ctl/pg_ctl.c ++++ b/src/bin/pg_ctl/pg_ctl.c +@@ -561,7 +561,7 @@ test_postmaster_connection(bool do_checkpoint) hostaddr = optlines[LOCK_FILE_LINE_LISTEN_ADDR - 1]; /* @@ -1138,10 +1158,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/bin/pg_ctl/pg_ctl.c postgresql-9.2.5/src * directories, libpq's host parameter must have a * leading slash to indicate a socket directory. So, * ignore sockdir if it's relative, and try to use TCP -diff -Naur -r postgresql-9.2.5.orig/src/include/libpq/libpq.h postgresql-9.2.5/src/include/libpq/libpq.h ---- postgresql-9.2.5.orig/src/include/libpq/libpq.h 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/include/libpq/libpq.h 2013-10-21 17:51:03.070676015 +0200 -@@ -44,12 +44,12 @@ +diff --git a/src/include/libpq/libpq.h b/src/include/libpq/libpq.h +index 6dd91ba..2bfec2b 100644 +--- a/src/include/libpq/libpq.h ++++ b/src/include/libpq/libpq.h +@@ -44,12 +44,12 @@ typedef struct /* * prototypes for functions in pqcomm.c */ @@ -1158,10 +1179,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/include/libpq/libpq.h postgresql-9.2.5/s extern void pq_init(void); extern void pq_comm_reset(void); extern int pq_getbytes(char *s, size_t len); -diff -Naur -r postgresql-9.2.5.orig/src/include/miscadmin.h postgresql-9.2.5/src/include/miscadmin.h ---- postgresql-9.2.5.orig/src/include/miscadmin.h 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/include/miscadmin.h 2013-10-21 17:51:03.070676015 +0200 -@@ -411,7 +411,7 @@ +diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h +index 1051ca4..e6c663c 100644 +--- a/src/include/miscadmin.h ++++ b/src/include/miscadmin.h +@@ -424,7 +424,7 @@ extern char *local_preload_libraries_string; * 2 data directory path * 3 postmaster start timestamp (time_t representation) * 4 port number @@ -1170,7 +1192,7 @@ diff -Naur -r postgresql-9.2.5.orig/src/include/miscadmin.h postgresql-9.2.5/src * 6 first listen_address (IP address or "*"; empty if no TCP port) * 7 shared memory key (not present on Windows) * -@@ -429,8 +429,9 @@ +@@ -442,8 +442,9 @@ extern char *local_preload_libraries_string; #define LOCK_FILE_LINE_SHMEM_KEY 7 extern void CreateDataDirLockFile(bool amPostmaster); @@ -1182,10 +1204,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/include/miscadmin.h postgresql-9.2.5/src extern void AddToDataDirLockFile(int target_line, const char *str); extern void ValidatePgVersion(const char *path); extern void process_shared_preload_libraries(void); -diff -Naur -r postgresql-9.2.5.orig/src/include/postmaster/postmaster.h postgresql-9.2.5/src/include/postmaster/postmaster.h ---- postgresql-9.2.5.orig/src/include/postmaster/postmaster.h 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/include/postmaster/postmaster.h 2013-10-21 17:51:03.071676021 +0200 -@@ -19,7 +19,7 @@ +diff --git a/src/include/postmaster/postmaster.h b/src/include/postmaster/postmaster.h +index 683ce3c..080a8ca 100644 +--- a/src/include/postmaster/postmaster.h ++++ b/src/include/postmaster/postmaster.h +@@ -19,7 +19,7 @@ extern int ReservedBackends; extern int PostPortNumber; extern int Unix_socket_permissions; extern char *Unix_socket_group; @@ -1194,10 +1217,11 @@ diff -Naur -r postgresql-9.2.5.orig/src/include/postmaster/postmaster.h postgres extern char *ListenAddresses; extern bool ClientAuthInProgress; extern int PreAuthDelay; -diff -Naur -r postgresql-9.2.5.orig/src/include/utils/builtins.h postgresql-9.2.5/src/include/utils/builtins.h ---- postgresql-9.2.5.orig/src/include/utils/builtins.h 2013-10-08 05:16:13.000000000 +0200 -+++ postgresql-9.2.5/src/include/utils/builtins.h 2013-10-21 17:51:03.071676021 +0200 -@@ -754,6 +754,8 @@ +diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h +index 4bf07e4..c830243 100644 +--- a/src/include/utils/builtins.h ++++ b/src/include/utils/builtins.h +@@ -754,6 +754,8 @@ extern int varstr_cmp(char *arg1, int len1, char *arg2, int len2, Oid collid); extern List *textToQualifiedNameList(text *textval); extern bool SplitIdentifierString(char *rawstring, char separator, List **namelist); @@ -1206,13 +1230,15 @@ diff -Naur -r postgresql-9.2.5.orig/src/include/utils/builtins.h postgresql-9.2. extern Datum replace_text(PG_FUNCTION_ARGS); extern text *replace_text_regexp(text *src_text, void *regexp, text *replace_text, bool glob); -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/html-stamp postgresql-9.2.5/doc/src/sgml/html-stamp ---- postgresql-9.2.5.orig/doc/src/sgml/html-stamp 2013-10-08 05:48:15.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/html-stamp 2013-10-21 17:51:03.071676021 +0200 +diff --git a/doc/src/sgml/html-stamp b/doc/src/sgml/html-stamp +index e69de29..fcf9276 100644 +--- a/doc/src/sgml/html-stamp ++++ b/doc/src/sgml/html-stamp @@ -0,0 +1 @@ +hack -diff -Naur -r postgresql-9.2.5.orig/doc/src/sgml/man-stamp postgresql-9.2.5/doc/src/sgml/man-stamp ---- postgresql-9.2.5.orig/doc/src/sgml/man-stamp 2013-10-08 05:49:22.000000000 +0200 -+++ postgresql-9.2.5/doc/src/sgml/man-stamp 2013-10-21 17:51:03.071676021 +0200 +diff --git a/doc/src/sgml/man-stamp b/doc/src/sgml/man-stamp +index e69de29..fcf9276 100644 +--- a/doc/src/sgml/man-stamp ++++ b/doc/src/sgml/man-stamp @@ -0,0 +1 @@ +hack diff --git a/SOURCES/postgresql-var-run-socket.patch b/SOURCES/postgresql-var-run-socket.patch index 22b8a0c..41ab3a0 100644 --- a/SOURCES/postgresql-var-run-socket.patch +++ b/SOURCES/postgresql-var-run-socket.patch @@ -15,11 +15,11 @@ override it via postgresql.conf.) This patch must be applied after postgresql-multi-sockets.patch, at least until 9.3 when that will be part of the upstream package. - -diff -Naur postgresql-9.2.2.sockets/contrib/pg_upgrade/test.sh postgresql-9.2.2/contrib/pg_upgrade/test.sh ---- postgresql-9.2.2.sockets/contrib/pg_upgrade/test.sh 2013-01-03 17:33:45.581567466 -0500 -+++ postgresql-9.2.2/contrib/pg_upgrade/test.sh 2013-01-03 17:40:22.923364917 -0500 -@@ -78,6 +78,12 @@ +diff --git a/contrib/pg_upgrade/test.sh b/contrib/pg_upgrade/test.sh +index d44c599..845b417 100644 +--- a/contrib/pg_upgrade/test.sh ++++ b/contrib/pg_upgrade/test.sh +@@ -121,6 +121,12 @@ logdir=$PWD/log rm -rf "$logdir" mkdir "$logdir" @@ -32,10 +32,11 @@ diff -Naur postgresql-9.2.2.sockets/contrib/pg_upgrade/test.sh postgresql-9.2.2/ # enable echo so the user can see what is being executed set -x -diff -Naur postgresql-9.2.2.sockets/src/backend/utils/misc/guc.c postgresql-9.2.2/src/backend/utils/misc/guc.c ---- postgresql-9.2.2.sockets/src/backend/utils/misc/guc.c 2013-01-03 17:37:56.632977951 -0500 -+++ postgresql-9.2.2/src/backend/utils/misc/guc.c 2013-01-03 17:38:30.183271588 -0500 -@@ -2901,7 +2901,7 @@ +diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c +index 1428cb6..3613732 100644 +--- a/src/backend/utils/misc/guc.c ++++ b/src/backend/utils/misc/guc.c +@@ -2901,7 +2901,7 @@ static struct config_string ConfigureNamesString[] = }, &Unix_socket_directories, #ifdef HAVE_UNIX_SOCKETS @@ -44,10 +45,11 @@ diff -Naur postgresql-9.2.2.sockets/src/backend/utils/misc/guc.c postgresql-9.2. #else "", #endif -diff -Naur postgresql-9.2.2.sockets/src/bin/initdb/initdb.c postgresql-9.2.2/src/bin/initdb/initdb.c ---- postgresql-9.2.2.sockets/src/bin/initdb/initdb.c 2013-01-03 17:37:56.633977974 -0500 -+++ postgresql-9.2.2/src/bin/initdb/initdb.c 2013-01-03 17:38:30.185271611 -0500 -@@ -1007,7 +1007,7 @@ +diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c +index 452ac0b..ce6ca96 100644 +--- a/src/bin/initdb/initdb.c ++++ b/src/bin/initdb/initdb.c +@@ -1015,7 +1015,7 @@ setup_config(void) #ifdef HAVE_UNIX_SOCKETS snprintf(repltok, sizeof(repltok), "#unix_socket_directories = '%s'", @@ -56,9 +58,10 @@ diff -Naur postgresql-9.2.2.sockets/src/bin/initdb/initdb.c postgresql-9.2.2/src #else snprintf(repltok, sizeof(repltok), "#unix_socket_directories = ''"); #endif -diff -Naur postgresql-9.2.2.sockets/src/include/pg_config_manual.h postgresql-9.2.2/src/include/pg_config_manual.h ---- postgresql-9.2.2.sockets/src/include/pg_config_manual.h 2012-12-03 15:16:10.000000000 -0500 -+++ postgresql-9.2.2/src/include/pg_config_manual.h 2013-01-03 17:38:30.185271611 -0500 +diff --git a/src/include/pg_config_manual.h b/src/include/pg_config_manual.h +index ee7dab0..f3e3ed9 100644 +--- a/src/include/pg_config_manual.h ++++ b/src/include/pg_config_manual.h @@ -144,7 +144,7 @@ * here's where to twiddle it. You can also override this at runtime * with the postmaster's -k switch. @@ -68,24 +71,3 @@ diff -Naur postgresql-9.2.2.sockets/src/include/pg_config_manual.h postgresql-9. /* * The random() function is expected to yield values between 0 and -diff -Naur postgresql-9.2.2.sockets/src/test/regress/pg_regress.c postgresql-9.2.2/src/test/regress/pg_regress.c ---- postgresql-9.2.2.sockets/src/test/regress/pg_regress.c 2012-12-03 15:16:10.000000000 -0500 -+++ postgresql-9.2.2/src/test/regress/pg_regress.c 2013-01-03 17:38:30.186271622 -0500 -@@ -772,7 +772,7 @@ - if (hostname != NULL) - doputenv("PGHOST", hostname); - else -- unsetenv("PGHOST"); -+ doputenv("PGHOST", "/tmp"); - unsetenv("PGHOSTADDR"); - if (port != -1) - { -@@ -2246,7 +2246,7 @@ - */ - header(_("starting postmaster")); - snprintf(buf, sizeof(buf), -- SYSTEMQUOTE "\"%s/postgres\" -D \"%s/data\" -F%s -c \"listen_addresses=%s\" > \"%s/log/postmaster.log\" 2>&1" SYSTEMQUOTE, -+ SYSTEMQUOTE "\"%s/postgres\" -D \"%s/data\" -F%s -c \"listen_addresses=%s\" -c \"unix_socket_directories=/tmp\" > \"%s/log/postmaster.log\" 2>&1" SYSTEMQUOTE, - bindir, temp_install, - debug ? " -d 5" : "", - hostname ? hostname : "", diff --git a/SPECS/postgresql.spec b/SPECS/postgresql.spec index 37fadd9..61e11e3 100644 --- a/SPECS/postgresql.spec +++ b/SPECS/postgresql.spec @@ -62,8 +62,8 @@ Summary: PostgreSQL client programs Name: postgresql %global majorversion 9.2 -Version: 9.2.7 -Release: 1%{?dist} +Version: 9.2.10 +Release: 2%{?dist} # The PostgreSQL license is very similar to other MIT licenses, but the OSI # recognizes it as an independent license, so we do as well. @@ -590,6 +590,10 @@ rm -f src/tutorial/GNUmakefile pushd contrib make MAX_CONNECTIONS=5 check popd + + pushd src/interfaces/ecpg + make MAX_CONNECTIONS=5 check + popd %endif # undo the "make clean" above @@ -1146,6 +1150,16 @@ fi %endif %changelog +* Tue Mar 10 2015 Pavel Raiskup - 9.2.10-2 +- enable ecpg testsuite + +* Thu Feb 05 2015 Pavel Raiskup - 9.2.10-1 +- update to 9.2.10 per release notes + http://www.postgresql.org/docs/9.2/static/release-9-2-10.html + http://www.postgresql.org/docs/9.2/static/release-9-2-9.html + http://www.postgresql.org/docs/9.2/static/release-9-2-8.html + (rhbz#1198672 rhbz#1198673) + * Tue Feb 18 2014 Pavel Raiskup - 9.2.7-1 - update to 9.2.7 per release notes (#1065845) http://www.postgresql.org/docs/9.2/static/release-9-2-7.html