Skip to Content.
Sympa Menu

freetds - Re: [freetds] segmentation fault when null field encountered

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Adam Perks" <adamperks81 AT gmail.com>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] segmentation fault when null field encountered
  • Date: Wed, 12 Jul 2006 11:23:21 +1000

Hi here is the gdb debugger output:

Core was generated by `php gmtest.php'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /lib64/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libcrypt.so.1
Reading symbols from /lib64/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libnsl.so.1
Reading symbols from /usr/lib64/libaspell.so.15...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libaspell.so.15
Reading symbols from /usr/lib64/libpspell.so.15...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libpspell.so.15
Reading symbols from /lib64/libpcre.so.0...
(no debugging symbols found)...done.
Loaded symbols for /lib64/libpcre.so.0
Reading symbols from /usr/lib64/libgmp.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libgmp.so.3
Reading symbols from /lib64/tls/libdb-4.3.so...(no debugging symbols found)...done.
Loaded symbols for /lib64/tls/libdb-4.3.so
Reading symbols from /usr/lib64/libcurl.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libcurl.so.3
Reading symbols from /usr/lib64/libbz2.so.1...
(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libbz2.so.1
Reading symbols from /usr/lib64/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libz.so.1
Reading symbols from /lib64/libresolv.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libresolv.so.2
Reading symbols from /lib64/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libm.so.6
Reading symbols from /lib64/libdl.so.2...
(no debugging symbols found)...done.
Loaded symbols for /lib64/libdl.so.2
Reading symbols from /usr/lib64/libxml2.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libxml2.so.2
Reading symbols from /usr/lib64/libgssapi_krb5.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libgssapi_krb5.so.2
Reading symbols from /usr/lib64/libkrb5.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libkrb5.so.3
Reading symbols from /usr/lib64/libk5crypto.so.3...
(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libk5crypto.so.3
Reading symbols from /lib64/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libcom_err.so.2
Reading symbols from /lib64/libssl.so.5...(no debugging symbols found)...done.
Loaded symbols for /lib64/libssl.so.5
Reading symbols from /lib64/libcrypto.so.5...(no debugging symbols found)...done.
Loaded symbols for /lib64/libcrypto.so.5
Reading symbols from /usr/lib64/libkrb5support.so.0...
(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libkrb5support.so.0
Reading symbols from /usr/lib64/libidn.so.11...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libidn.so.11
Reading symbols from /lib64/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libc.so.6
Reading symbols from /usr/lib64/libstdc++.so.6...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libstdc++.so.6
Reading symbols from /lib64/libgcc_s.so.1...
(no debugging symbols found)...done.
Loaded symbols for /lib64/libgcc_s.so.1
Reading symbols from /lib64/libpthread.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib64/libpthread.so.0
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Reading symbols from /lib64/libnss_files.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libnss_files.so.2
Reading symbols from /usr/lib64/php/modules/mysql.so...
(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/php/modules/mysql.so
Reading symbols from /usr/lib64/mysql/libmysqlclient.so.14...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/mysql/libmysqlclient.so.14
Reading symbols from /usr/lib64/php/modules/mysqli.so...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/php/modules/mysqli.so
Reading symbols from /usr/lib64/php/modules/odbc.so...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/php/modules/odbc.so
Reading symbols from /usr/lib64/libodbc.so.1...
(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libodbc.so.1
Reading symbols from /usr/lib64/libodbcpsql.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/libodbcpsql.so.2
Reading symbols from /lib64/libnss_compat.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libnss_compat.so.2
Reading symbols from /lib64/libnss_nis.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libnss_nis.so.2
Reading symbols from /usr/lib64/gconv/ISO8859-1.so...
(no debugging symbols found)...done.
Loaded symbols for /usr/lib64/gconv/ISO8859-1.so
Reading symbols from /usr/local/lib/libtdsodbc.so...done.
Loaded symbols for /usr/local/lib/libtdsodbc.so
Reading symbols from /usr/local/lib/libodbcinst.so.1...done.
Loaded symbols for /usr/local/lib/libodbcinst.so.1
Reading symbols from /lib64/libnss_dns.so.2...done.
Loaded symbols for /lib64/libnss_dns.so.2
Reading symbols from /usr/lib64/gconv/CP1252.so...done.
Loaded symbols for /usr/lib64/gconv/CP1252.so
#0 0x0000003d82473da6 in memcpy () from /lib64/libc.so.6

Regards,
Adam

Hi All,

I have FreeTDS working on two machines: and i386 and an x64
both running Fedora Core 4 32bit and 64bit versions
respectively. The i386 machine works fine, however the x64
crashes when a null result is returned with $whatever =
odbc_result($result, 1);

Both PCs are set up the same, and I installed the FC4 FreeTDS
packages in the same way. isql & tsql also work perfectly
with both and I have configured the FreeTDS configuration &
unixODBC configurations the same. The necessary PHP modules
have also been installed and configured correctly.


Well, so you are using a PHP script with a stack like

PHP <=> php_odbc <=> ODBC <=> FreeTDS <=> sql server

I suspect a bug in one of the first 4... probably from php_odbc to
FreeTDS.

I would
- simplify script at minimun
- be able to execute script from command line
- enale core (ulimit -c unlimited)
- launch script (php script.php)
- load core with gdb (gdb $(which php) core.xxx)
- dump stack (bt)

Does this seem like a problem relating the 64bit FC4 package
or something else?

Any help would be greatly appreciated- I have spent three
days trying to get this to work!

Currently I don't have a x64 environment to play with :)

freddy77





Archive powered by MHonArc 2.6.24.

Top of Page