Adding patch from Toni Mueller <support@oeko.net> to fix SQL for postgresql 8.4 (Closes: #568119).

bzr revid: p_christ@hol.gr-20101019095502-z3qzefpofohdy6tt
This commit is contained in:
Daniel Baumann 2010-10-19 12:55:02 +03:00 committed by P. Christeas
parent 6c68bd3b42
commit 444801e11b
2 changed files with 16 additions and 0 deletions

15
debian/patches/05-postgresql-8.4.patch vendored Normal file
View File

@ -0,0 +1,15 @@
Author: Toni Mueller <support@oeko.net>
Description: Fixes SQL for postgresql 8.4 (Closes: #568119).
diff -Naurp openerp-server.orig/bin/service/web_services.py openerp-server/bin/service/web_services.py
--- openerp-server.orig/bin/service/web_services.py 2009-11-27 17:41:16.000000000 +0100
+++ openerp-server/bin/service/web_services.py 2010-02-06 10:18:46.000000000 +0100
@@ -75,7 +75,7 @@ class db(netsvc.Service):
cr = db.serialized_cursor()
try:
cr.autocommit(True) # XXX inhibit the effect of a serialized cursor. is it what we want ?
- cr.execute('CREATE DATABASE "%s" ENCODING \'unicode\'' % db_name)
+ cr.execute('CREATE DATABASE "%s" ENCODING \'unicode\' TEMPLATE template0' % db_name)
finally:
cr.close()
sql_db.close_db('template1')

View File

@ -1,3 +1,4 @@
01-autobuild.patch
02-migrate.patch
03-shebang.patch
05-postgresql-8.4.patch