Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 279576 - dev-lang/php-5.2.10: patch for pdo dblib error
Summary: dev-lang/php-5.2.10: patch for pdo dblib error
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: PHP Bugs
URL: http://bugs.php.net/bug.php?id=48539
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-29 12:24 UTC by oc666
Modified: 2009-09-27 03:01 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description oc666 2009-07-29 12:24:15 UTC
PHP can't connect to DB servers with pdo_dblib library.


Reproducible: Always

Steps to Reproduce:
1. Example of php code: $dbh = new PDO ("dblib:host=$hostname;dbname=$dbname","$username","$pw");
Actual Results:  
Output: SQLSTATE[] (null) (severity 0) 

Expected Results:  
the command need to be without any output.

The patch to include:
--- ext/pdo_dblib/dblib_driver.c.orig   2009-03-20 23:14:17.000000000
+0100
+++ ext/pdo_dblib/dblib_driver.c   2009-06-28 01:50:50.000000000 +0200
@@ -230,9 +230,9 @@
       goto cleanup;
    }
 
-   if (DBSETOPT(H->link, DBTEXTLIMIT, "2147483647") == FAIL) {
-      goto cleanup;
-   }
+//   if (DBSETOPT(H->link, DBTEXTLIMIT, "2147483647") == FAIL) {
+//      goto cleanup;
+//   }
 
    if (vars[3].optval && FAIL == dbuse(H->link, vars[3].optval)) {
       goto cleanup;
Comment 1 James Earl Spahlinger 2009-07-30 00:03:40 UTC
Can you tell us what version of php and the relevant libraries you are using please as well as include your 'emerge --info'. Thanks
Comment 2 oc666 2009-07-30 00:11:26 UTC
The package is dev-lang/php-5.2.10
# emerge --info
Portage 2.1.6.13 (default/linux/amd64/2008.0, gcc-4.3.2, glibc-2.9_p20081201-r2, 2.6.29-gentoo-r5 x86_64)
=================================================================
System uname: Linux-2.6.29-gentoo-r5-x86_64-Intel-R-_Pentium-R-_D_CPU_2.80GHz-with-glibc2.2.5
Timestamp of tree: Tue, 28 Jul 2009 08:45:02 +0000
app-shells/bash:     3.2_p39
dev-lang/python:     2.5.4-r3
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.63-r1
sys-devel/automake:  1.7.9-r1, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=nocona -O2 -pipe -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/qmail/alias /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-march=nocona -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://mirror.hamakor.org.il/pub/mirrors/gentoo/"
LANG="he_IL.UTF-8"
LC_ALL="he_IL.UTF-8"
LDFLAGS="-Wl,-O1"
LINGUAS="en he"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://mirror.hamakor.org.il/gentoo-portage"
USE="acl acpi amd64 apache apache2 bash-completion berkdb bzip2 cli cracklib crypt dbx dri fastcgi fortran freetds ftp gd gdbm gif gpm iconv imagemagick imap ipv6 isdnlog jpeg ldap maildir midi mmx mpeg mssql mudflap multilib mysql mysqli ncurses nls nptl nptlonly ntfs odbc openmp pam pcre pdf perl php php5 png pppd python readline reflection reiserfs reuse samba session simplexml spl sqlite sse sse2 ssh ssl symlink sysfs tcpd tiff truetype unicode urandom utf8 v4l vhosts web xml xml2 xorg xsl zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en he" USERLAND="GNU" VIDEO_CARDS="fbdev glint i810 intel mach64 mga neomagic nv r128 radeon savage sis tdfx trident vesa vga via vmware voodoo"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, MAKEOPTS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

# emerge -ptv php

These are the packages that would be merged, in reverse order:

Calculating dependencies... done!
[ebuild   R   ] dev-lang/php-5.2.10  USE="apache2 berkdb bzip2 cli crypt curl ftp gd gdbm iconv imap ipv6 json ldap mssql mysql mysqli ncurses nls odbc pcre pdo readline reflection session simplexml spl sqlite ssl truetype unicode xml xsl yaz zip zlib (-adabas) -bcmath (-birdstep) -calendar -cdb -cgi -cjk -concurrentmodphp -ctype -curlwrappers -db2 -dbase (-dbmaker) -debug -discard-path -doc (-empress) (-empress-bcs) (-esoob) -exif -fastbuild (-fdftk) -filter (-firebird) -flatfile -force-cgi-redirect (-frontbase) -gd-external -gmp -hash -inifile -interbase -iodbc (-java-external) -kerberos -kolab -ldap-sasl -libedit -mcve -mhash -msql -oci8 -oci8-instant-client -pcntl -pic -posix -postgres -qdbm -recode -sapdb -sharedext -sharedmem -snmp -soap -sockets (-solid) -spell -suhosin (-sybase) (-sybase-ct) -sysvipc -threads -tidy -tokenizer -wddx -xmlreader -xmlrpc -xmlwriter -xpm"

The problematic library is pdo_dblib.
Comment 3 Wormo (RETIRED) gentoo-dev 2009-07-30 23:23:39 UTC
Thanks for reporting both the problem and a solution. Assigning to php maintainers.
Comment 4 Dawid Węgliński (RETIRED) gentoo-dev 2009-09-24 23:35:11 UTC
This backport comes with 5.2.10-r2 now. Note that this revision includes patchset from 5.2.10-r1 which is not marked stable yet.

@php are you ok with -r2 going stable? If yes, please reopen and CC arches.
Comment 5 oc666 2009-09-27 03:01:42 UTC
I just update to the new package (5.2.10-r2) and it's working perfect (the patch fixed the bug).