SOURCES: postgresql.init, postgresql.sysconfig - use C locale for initaliza...

arekm arekm at pld-linux.org
Sat Jul 5 23:37:10 CEST 2008


Author: arekm                        Date: Sat Jul  5 21:37:10 2008 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- use C locale for initalization by default; it's safer than other loclaes;  https://bugs.launchpad.net/ubuntu/+source/postgresql-common/+bug/207779

---- Files affected:
SOURCES:
   postgresql.init (1.75 -> 1.76) , postgresql.sysconfig (1.21 -> 1.22) 

---- Diffs:

================================================================
Index: SOURCES/postgresql.init
diff -u SOURCES/postgresql.init:1.75 SOURCES/postgresql.init:1.76
--- SOURCES/postgresql.init:1.75	Tue Feb 19 22:29:55 2008
+++ SOURCES/postgresql.init	Sat Jul  5 23:37:04 2008
@@ -18,6 +18,8 @@
 # Get network config
 . /etc/sysconfig/network
 
+PG_INIT_LOCALE=C
+
 # Get service config
 if [ -f /etc/sysconfig/postgresql ]; then
 	. /etc/sysconfig/postgresql
@@ -245,7 +247,7 @@
 			mkdir -p $pgdir
 			chmod 700 $pgdir
 			chown postgres:postgres $pgdir
-			TMPDIR=/tmp su postgres -s /bin/sh -c "initdb -E UNICODE -D $pgdir"
+			LC_ALL=$PG_INIT_LOCALE TMPDIR=/tmp su postgres -s /bin/sh -c "initdb -E UNICODE -D $pgdir"
 		fi
 	done
 	echo $(nls "REMEMBER to setup password for user \"postgres\"")'!'

================================================================
Index: SOURCES/postgresql.sysconfig
diff -u SOURCES/postgresql.sysconfig:1.21 SOURCES/postgresql.sysconfig:1.22
--- SOURCES/postgresql.sysconfig:1.21	Sat Jul 23 20:09:26 2005
+++ SOURCES/postgresql.sysconfig	Sat Jul  5 23:37:05 2008
@@ -6,6 +6,9 @@
 # you should change TCP/IP port, at least.
 #
 
+# locale used at service postgresql init
+# PG_INIT_LOCALE=C
+
 # standard setting
 PG_DB_CLUSTERS="/var/lib/pgsql"
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/postgresql.init?r1=1.75&r2=1.76&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/postgresql.sysconfig?r1=1.21&r2=1.22&f=u



More information about the pld-cvs-commit mailing list