From:             vesely at tana dot it
Operating system: unix
PHP version:      4.4.4
PHP Bug Type:     Reproducible crash
Bug description:  BDB-4.5 include, older BDB linked

Description:
------------
Please add tests for db-4.5 and newer: the compilation does not fail if by
chance an older db-4.1 (in my case) existed.
However, when calling dbd->set_errcall the process crashes with pc=0. That
happens because the DB structure changed and newer elements have been
inserted in the middle of it, rather than at the bottom.

Hopefully, one day BDB will come with an official m4 macro. I already
asked them...

One more thing, the errcall has different arguments in 4.5:
--- ./ext/dba/dba_db4.c%    2006-11-27 23:54:31.021697000 +0100
+++ ./ext/dba/dba_db4.c    2006-11-27 23:54:31.031696000 +0100
@@ -35,7 +35,7 @@
#include <db.h>
#endif

-static void php_dba_db4_errcall_fcn(const char *errpfx, char *msg)
+static void php_dba_db4_errcall_fcn(const DB_ENV*env, const char *errpfx,
const char *msg)
{
    TSRMLS_FETCH();
     


Reproduce code:
---------------
This was trapped in the test suite. (Since the program aborted its output
was different.)


Expected result:
----------------
database handler: db4
3NYNYY
Content String 2
Content 2 replaced
Read during write: not allowed
Content 2 replaced 2nd time
The 6th value
array(3) {
 ["key number 6"]=>
 string(13) "The 6th value"
 ["key2"]=>
 string(27) "Content 2 replaced 2nd time"
 ["key5"]=>
 string(23) "The last content string"
}


Actual result:
--------------
database handler: db4

-- 
Edit bug report at http://bugs.php.net/?id=39653&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=39653&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=39653&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=39653&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=39653&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=39653&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=39653&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=39653&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=39653&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=39653&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=39653&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=39653&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=39653&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=39653&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=39653&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=39653&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=39653&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=39653&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=39653&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=39653&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=39653&r=mysqlcfg

Reply via email to