p5-DBD-Pg
Jun Kuriyama
kuriyama at imgsrc.co.jp
Tue Mar 8 13:46:07 GMT 2005
My patch was wrong. Original developers are working on this problem.
Can you try with this?
Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/databases/p5-DBD-Pg/Makefile,v
retrieving revision 1.61
diff -u -r1.61 Makefile
--- Makefile 2 Mar 2005 18:18:57 -0000 1.61
+++ Makefile 6 Mar 2005 13:27:57 -0000
@@ -7,6 +7,7 @@
PORTNAME= DBD-Pg
PORTVERSION= 1.40
+PORTREVISION= 1
CATEGORIES= databases perl5
MASTER_SITES= ${MASTER_SITE_PERL_CPAN}
MASTER_SITE_SUBDIR= DBD
Index: files/patch-dbdimp.c
===================================================================
RCS file: files/patch-dbdimp.c
diff -N files/patch-dbdimp.c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ files/patch-dbdimp.c 8 Mar 2005 13:42:45 -0000
@@ -0,0 +1,42 @@
+--- dbdimp.c.orig Tue Mar 8 22:41:12 2005
++++ dbdimp.c Tue Mar 8 22:41:36 2005
+@@ -1,6 +1,6 @@
+ /*
+
+- $Id: dbdimp.c,v 1.98 2005/01/29 18:53:52 turnstep Exp $
++ $Id: dbdimp.c,v 1.99 2005/03/07 23:40:45 turnstep Exp $
+
+ Copyright (c) 2002-2005 PostgreSQL Global Development Group
+ Portions Copyright (c) 2002 Jeffrey W. Baker
+@@ -793,7 +793,7 @@
+ 2. The attribute "direct" is false
+ 3. We can handle server-side prepares
+ 4. The attribute "pg_server_prepare" is not 0
+- 5. The attribute "pg_prepare_now" is true
++ 5. The attribute "pg_prepare_now" is true and we are a PG8 or up compiled server
+ */
+ if (imp_sth->is_dml &&
+ !imp_sth->direct &&
+@@ -1517,7 +1517,9 @@
+ execsize = imp_sth->totalsize; /* Total of all segments */
+
+ /* If using plain old PQexec, we need to quote each value ourselves */
+- if (imp_dbh->pg_protocol < 3) {
++ if (imp_dbh->pg_protocol < 3 ||
++ (1 != imp_sth->server_prepare &&
++ imp_sth->numbound != imp_sth->numphs)) {
+ for (currph=imp_sth->ph; NULL != currph; currph=currph->nextph) {
+ if (NULL == currph->value) {
+ Renew(currph->quoted, 5, char); /* freed in dbd_st_execute (and above) */
+@@ -1628,7 +1630,10 @@
+
+ /* PQexecParams */
+
+- if (imp_dbh->pg_protocol >= 3 && imp_sth->numphs) {
++ if (imp_dbh->pg_protocol >= 3 &&
++ imp_sth->numphs &&
++ (1 == imp_sth->server_prepare ||
++ imp_sth->numbound == imp_sth->numphs)) {
+
+ if (dbis->debug >= 5)
+ PerlIO_printf(DBILOGFP, " dbdpg: using PQexecParams\n");
--
Jun Kuriyama <kuriyama at imgsrc.co.jp> // IMG SRC, Inc.
<kuriyama at FreeBSD.org> // FreeBSD Project
More information about the freebsd-perl
mailing list