summaryrefslogtreecommitdiff
path: root/ext/dba
diff options
context:
space:
mode:
Diffstat (limited to 'ext/dba')
-rw-r--r--ext/dba/config.m42
-rw-r--r--ext/dba/config.w322
-rw-r--r--ext/dba/dba.c2
-rw-r--r--ext/dba/dba_cdb.c2
-rwxr-xr-xext/dba/dba_db1.c2
-rw-r--r--ext/dba/dba_db2.c2
-rw-r--r--ext/dba/dba_db3.c2
-rw-r--r--ext/dba/dba_db4.c10
-rw-r--r--ext/dba/dba_dbm.c2
-rw-r--r--ext/dba/dba_flatfile.c2
-rw-r--r--ext/dba/dba_gdbm.c2
-rw-r--r--ext/dba/dba_inifile.c2
-rw-r--r--ext/dba/dba_ndbm.c2
-rwxr-xr-xext/dba/dba_qdbm.c2
-rwxr-xr-xext/dba/install_cdb.sh2
-rw-r--r--ext/dba/libcdb/cdb.c4
-rw-r--r--ext/dba/libcdb/cdb.h2
-rw-r--r--ext/dba/libcdb/cdb_make.c4
-rw-r--r--ext/dba/libcdb/cdb_make.h2
-rw-r--r--ext/dba/libcdb/uint32.c2
-rw-r--r--ext/dba/libcdb/uint32.h2
-rw-r--r--ext/dba/libflatfile/flatfile.c4
-rw-r--r--ext/dba/libflatfile/flatfile.h2
-rw-r--r--ext/dba/libinifile/inifile.c4
-rw-r--r--ext/dba/libinifile/inifile.h2
-rw-r--r--ext/dba/php_dba.h2
-rwxr-xr-xext/dba/tests/bug36436.phpt4
-rw-r--r--ext/dba/tests/bug48240.phpt4
-rw-r--r--ext/dba/tests/bug49125.phpt27
-rw-r--r--ext/dba/tests/dba001.phpt6
-rw-r--r--ext/dba/tests/dba002.phpt4
-rw-r--r--ext/dba/tests/dba003.phpt4
-rw-r--r--ext/dba/tests/dba004.phpt4
-rw-r--r--ext/dba/tests/dba005.phpt4
-rw-r--r--ext/dba/tests/dba006.phpt6
-rw-r--r--ext/dba/tests/dba007.phpt4
-rw-r--r--ext/dba/tests/dba008.phpt4
-rwxr-xr-xext/dba/tests/dba009.phpt4
-rw-r--r--ext/dba/tests/dba_cdb.phpt6
-rw-r--r--ext/dba/tests/dba_cdb_make.phpt4
-rw-r--r--ext/dba/tests/dba_cdb_read.phpt4
-rwxr-xr-xext/dba/tests/dba_db1.phpt6
-rw-r--r--ext/dba/tests/dba_db2.phpt6
-rw-r--r--ext/dba/tests/dba_db3.phpt6
-rw-r--r--ext/dba/tests/dba_db4.phpt6
-rw-r--r--ext/dba/tests/dba_dbm.phpt6
-rw-r--r--ext/dba/tests/dba_flatfile.phpt6
-rw-r--r--ext/dba/tests/dba_gdbm.phpt6
-rw-r--r--ext/dba/tests/dba_inifile.phpt6
-rw-r--r--ext/dba/tests/dba_ndbm.phpt6
-rwxr-xr-xext/dba/tests/dba_qdbm.phpt6
-rw-r--r--ext/dba/tests/test.inc4
52 files changed, 128 insertions, 93 deletions
diff --git a/ext/dba/config.m4 b/ext/dba/config.m4
index a77adc01b..feed36e25 100644
--- a/ext/dba/config.m4
+++ b/ext/dba/config.m4
@@ -1,5 +1,5 @@
dnl
-dnl $Id: config.m4,v 1.70.2.2.2.8.2.2 2007/12/06 14:01:49 helly Exp $
+dnl $Id: config.m4 247692 2007-12-06 14:01:49Z helly $
dnl
dnl Suppose we need FlatFile if no support or only CDB is used.
diff --git a/ext/dba/config.w32 b/ext/dba/config.w32
index 2239009dc..1f72019f4 100644
--- a/ext/dba/config.w32
+++ b/ext/dba/config.w32
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.3 2005/02/26 01:05:33 helly Exp $
+// $Id: config.w32 180813 2005-02-26 01:05:33Z helly $
// vim:ft=javascript
ARG_WITH("dba", "DBA support", "no");
diff --git a/ext/dba/dba.c b/ext/dba/dba.c
index 991c257dd..d59b1f2b1 100644
--- a/ext/dba/dba.c
+++ b/ext/dba/dba.c
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba.c,v 1.111.2.4.2.5.2.10 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_cdb.c b/ext/dba/dba_cdb.c
index a436875bb..61c1df5bf 100644
--- a/ext/dba/dba_cdb.c
+++ b/ext/dba/dba_cdb.c
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_cdb.c,v 1.32.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_cdb.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_db1.c b/ext/dba/dba_db1.c
index 7bc348ee9..202ef6918 100755
--- a/ext/dba/dba_db1.c
+++ b/ext/dba/dba_db1.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_db1.c,v 1.3.2.1.2.1.2.3 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_db1.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_db2.c b/ext/dba/dba_db2.c
index b12606a3b..6b3111146 100644
--- a/ext/dba/dba_db2.c
+++ b/ext/dba/dba_db2.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_db2.c,v 1.39.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_db2.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_db3.c b/ext/dba/dba_db3.c
index a229cb429..3b090ca60 100644
--- a/ext/dba/dba_db3.c
+++ b/ext/dba/dba_db3.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_db3.c,v 1.33.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_db3.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_db4.c b/ext/dba/dba_db4.c
index 2c2da4052..bdf9cdfbd 100644
--- a/ext/dba/dba_db4.c
+++ b/ext/dba/dba_db4.c
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_db4.c,v 1.15.2.3.2.1.2.4 2009/05/13 02:14:53 felipe Exp $ */
+/* $Id: dba_db4.c 286636 2009-08-01 23:10:11Z felipe $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -175,7 +175,15 @@ DBA_EXISTS_FUNC(db4)
DB4_GKEY;
memset(&gval, 0, sizeof(gval));
+
+ if (info->flags & DBA_PERSISTENT) {
+ gval.flags |= DB_DBT_MALLOC;
+ }
+
if (!dba->dbp->get(dba->dbp, NULL, &gkey, &gval, 0)) {
+ if (info->flags & DBA_PERSISTENT) {
+ free(gval.data);
+ }
return SUCCESS;
}
return FAILURE;
diff --git a/ext/dba/dba_dbm.c b/ext/dba/dba_dbm.c
index a65510208..9e323694e 100644
--- a/ext/dba/dba_dbm.c
+++ b/ext/dba/dba_dbm.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_dbm.c,v 1.29.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_dbm.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_flatfile.c b/ext/dba/dba_flatfile.c
index 617c81bda..849ce3ace 100644
--- a/ext/dba/dba_flatfile.c
+++ b/ext/dba/dba_flatfile.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_flatfile.c,v 1.19.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_flatfile.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_gdbm.c b/ext/dba/dba_gdbm.c
index 63ddef82e..d7a0c929f 100644
--- a/ext/dba/dba_gdbm.c
+++ b/ext/dba/dba_gdbm.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_gdbm.c,v 1.23.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_gdbm.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_inifile.c b/ext/dba/dba_inifile.c
index bbea05ddb..0cd2f28c9 100644
--- a/ext/dba/dba_inifile.c
+++ b/ext/dba/dba_inifile.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_inifile.c,v 1.5.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_inifile.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_ndbm.c b/ext/dba/dba_ndbm.c
index c74d761b4..3860039b4 100644
--- a/ext/dba/dba_ndbm.c
+++ b/ext/dba/dba_ndbm.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_ndbm.c,v 1.19.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_ndbm.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/dba_qdbm.c b/ext/dba/dba_qdbm.c
index 94fb9fc67..b3a9c35c4 100755
--- a/ext/dba/dba_qdbm.c
+++ b/ext/dba/dba_qdbm.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dba_qdbm.c,v 1.4.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: dba_qdbm.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
diff --git a/ext/dba/install_cdb.sh b/ext/dba/install_cdb.sh
index 82396b922..ce5f3cc85 100755
--- a/ext/dba/install_cdb.sh
+++ b/ext/dba/install_cdb.sh
@@ -8,7 +8,7 @@
# library which programs can link against. This shell script fills
# the gap.
#
-# $Id: install_cdb.sh,v 1.2 2002/11/04 17:53:04 helly Exp $
+# $Id: install_cdb.sh,v 1.2 2002-11-04 17:53:04 helly Exp $
if test -r "cdb.a" && test -r "auto-str.c" && test -r "byte.a"; then
:
diff --git a/ext/dba/libcdb/cdb.c b/ext/dba/libcdb/cdb.c
index 9fccda705..6d5f3aaf8 100644
--- a/ext/dba/libcdb/cdb.c
+++ b/ext/dba/libcdb/cdb.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: cdb.c,v 1.10.2.1.2.3.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: cdb.c 272370 2008-12-31 11:15:49Z sebastian $ */
/* incorporated from D.J.Bernstein's cdb-0.75 (http://cr.yp.to/cdb.html)*/
@@ -189,6 +189,6 @@ int cdb_find(struct cdb *c, char *key, unsigned int len TSRMLS_DC)
/* {{{ cdb_version */
char *cdb_version()
{
- return "0.75, $Revision: 1.10.2.1.2.3.2.2 $";
+ return "0.75, $Revision: 272370 $";
}
/* }}} */
diff --git a/ext/dba/libcdb/cdb.h b/ext/dba/libcdb/cdb.h
index 14e6cb3ae..858e9a36c 100644
--- a/ext/dba/libcdb/cdb.h
+++ b/ext/dba/libcdb/cdb.h
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: cdb.h,v 1.7.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: cdb.h 272370 2008-12-31 11:15:49Z sebastian $ */
/* incorporated from D.J.Bernstein's cdb-0.75 (http://cr.yp.to/cdb.html)*/
diff --git a/ext/dba/libcdb/cdb_make.c b/ext/dba/libcdb/cdb_make.c
index 81e001e3d..180d192c4 100644
--- a/ext/dba/libcdb/cdb_make.c
+++ b/ext/dba/libcdb/cdb_make.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: cdb_make.c,v 1.9.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: cdb_make.c 272370 2008-12-31 11:15:49Z sebastian $ */
/* incorporated from D.J.Bernstein's cdb-0.75 (http://cr.yp.to/cdb.html)*/
@@ -240,5 +240,5 @@ int cdb_make_finish(struct cdb_make *c TSRMLS_DC)
/* {{{ cdb_make_version */
char *cdb_make_version()
{
- return "0.75, $Revision: 1.9.2.1.2.1.2.2 $";
+ return "0.75, $Revision: 272370 $";
}
diff --git a/ext/dba/libcdb/cdb_make.h b/ext/dba/libcdb/cdb_make.h
index f341124c1..a0fea70ce 100644
--- a/ext/dba/libcdb/cdb_make.h
+++ b/ext/dba/libcdb/cdb_make.h
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: cdb_make.h,v 1.7.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: cdb_make.h 272370 2008-12-31 11:15:49Z sebastian $ */
/* incorporated from D.J.Bernstein's cdb-0.75 (http://cr.yp.to/cdb.html)*/
diff --git a/ext/dba/libcdb/uint32.c b/ext/dba/libcdb/uint32.c
index a45a3e66c..29df68c4c 100644
--- a/ext/dba/libcdb/uint32.c
+++ b/ext/dba/libcdb/uint32.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: uint32.c,v 1.6.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: uint32.c 272370 2008-12-31 11:15:49Z sebastian $ */
/* incorporated from D.J.Bernstein's cdb-0.75 (http://cr.yp.to/cdb.html)*/
diff --git a/ext/dba/libcdb/uint32.h b/ext/dba/libcdb/uint32.h
index 2675653b9..df31e4c24 100644
--- a/ext/dba/libcdb/uint32.h
+++ b/ext/dba/libcdb/uint32.h
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: uint32.h,v 1.6.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: uint32.h 272370 2008-12-31 11:15:49Z sebastian $ */
/* incorporated from D.J.Bernstein's cdb-0.75 (http://cr.yp.to/cdb.html)*/
diff --git a/ext/dba/libflatfile/flatfile.c b/ext/dba/libflatfile/flatfile.c
index fff029b85..16216b4fe 100644
--- a/ext/dba/libflatfile/flatfile.c
+++ b/ext/dba/libflatfile/flatfile.c
@@ -19,7 +19,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: flatfile.c,v 1.14.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: flatfile.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -307,7 +307,7 @@ datum flatfile_nextkey(flatfile *dba TSRMLS_DC) {
/* {{{ flatfile_version */
char *flatfile_version()
{
- return "1.0, $Revision: 1.14.2.1.2.1.2.2 $";
+ return "1.0, $Revision: 272370 $";
}
/* }}} */
diff --git a/ext/dba/libflatfile/flatfile.h b/ext/dba/libflatfile/flatfile.h
index 864903bca..3de35871d 100644
--- a/ext/dba/libflatfile/flatfile.h
+++ b/ext/dba/libflatfile/flatfile.h
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: flatfile.h,v 1.11.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: flatfile.h 272370 2008-12-31 11:15:49Z sebastian $ */
#ifndef PHP_LIB_FLATFILE_H
#define PHP_LIB_FLATFILE_H
diff --git a/ext/dba/libinifile/inifile.c b/ext/dba/libinifile/inifile.c
index df4070cfe..acc479248 100644
--- a/ext/dba/libinifile/inifile.c
+++ b/ext/dba/libinifile/inifile.c
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: inifile.c,v 1.14.2.1.2.3.2.3 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: inifile.c 272370 2008-12-31 11:15:49Z sebastian $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -43,7 +43,7 @@
/* {{{ inifile_version */
char *inifile_version()
{
- return "1.0, $Revision: 1.14.2.1.2.3.2.3 $";
+ return "1.0, $Revision: 272370 $";
}
/* }}} */
diff --git a/ext/dba/libinifile/inifile.h b/ext/dba/libinifile/inifile.h
index 68c167533..81806f1cb 100644
--- a/ext/dba/libinifile/inifile.h
+++ b/ext/dba/libinifile/inifile.h
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: inifile.h,v 1.5.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: inifile.h 272370 2008-12-31 11:15:49Z sebastian $ */
#ifndef PHP_LIB_INIFILE_H
#define PHP_LIB_INIFILE_H
diff --git a/ext/dba/php_dba.h b/ext/dba/php_dba.h
index 45f38b9a5..fccb2ee6d 100644
--- a/ext/dba/php_dba.h
+++ b/ext/dba/php_dba.h
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_dba.h,v 1.29.2.1.2.1.2.2 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: php_dba.h 272370 2008-12-31 11:15:49Z sebastian $ */
#ifndef PHP_DBA_H
#define PHP_DBA_H
diff --git a/ext/dba/tests/bug36436.phpt b/ext/dba/tests/bug36436.phpt
index 60470660e..4e8daa860 100755
--- a/ext/dba/tests/bug36436.phpt
+++ b/ext/dba/tests/bug36436.phpt
@@ -3,13 +3,13 @@ Bug #36436 (DBA problem with Berkeley DB4)
--SKIPIF--
<?php
$handler = 'db4';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'db4';
-require_once('test.inc');
+require_once dirname(__FILE__) .'/test.inc';
$db = dba_popen($db_filename, 'c', 'db4');
diff --git a/ext/dba/tests/bug48240.phpt b/ext/dba/tests/bug48240.phpt
index 72dc43956..27f8d95e6 100644
--- a/ext/dba/tests/bug48240.phpt
+++ b/ext/dba/tests/bug48240.phpt
@@ -3,13 +3,13 @@ Bug #48240 (DBA Segmentation fault dba_nextkey)
--SKIPIF--
<?php
$handler = 'db4';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'db4';
-require_once('test.inc');
+require_once dirname(__FILE__) .'/test.inc';
$db = dba_open($db_filename, 'c', 'db4');
diff --git a/ext/dba/tests/bug49125.phpt b/ext/dba/tests/bug49125.phpt
new file mode 100644
index 000000000..3724b89c9
--- /dev/null
+++ b/ext/dba/tests/bug49125.phpt
@@ -0,0 +1,27 @@
+--TEST--
+Bug #49125 (Error in dba_exists C code)
+--SKIPIF--
+<?php
+ $handler = 'db4';
+ require_once dirname(__FILE__) .'/skipif.inc';
+?>
+--FILE--
+<?php
+
+error_reporting(E_ALL);
+
+$handler = 'db4';
+require_once dirname(__FILE__) .'/test.inc';
+
+$db = dba_popen($db_filename, 'c', 'db4');
+
+dba_insert('foo', 'foo', $db);
+
+var_dump(dba_exists('foo', $db));
+
+dba_close($db);
+
+unlink($db_filename);
+
+--EXPECT--
+bool(true)
diff --git a/ext/dba/tests/dba001.phpt b/ext/dba/tests/dba001.phpt
index 3d617fb2c..00aec6969 100644
--- a/ext/dba/tests/dba001.phpt
+++ b/ext/dba/tests/dba001.phpt
@@ -2,12 +2,12 @@
DBA File Creation Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
echo "database file created\n";
@@ -18,4 +18,4 @@ DBA File Creation Test
?>
--EXPECTF--
database handler: %s
-database file created \ No newline at end of file
+database file created
diff --git a/ext/dba/tests/dba002.phpt b/ext/dba/tests/dba002.phpt
index 3f862e38c..974b09fab 100644
--- a/ext/dba/tests/dba002.phpt
+++ b/ext/dba/tests/dba002.phpt
@@ -2,12 +2,12 @@
DBA Insert/Fetch Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
dba_insert("key1", "This is a test insert", $db_file);
diff --git a/ext/dba/tests/dba003.phpt b/ext/dba/tests/dba003.phpt
index 617ae9189..832c7a0dc 100644
--- a/ext/dba/tests/dba003.phpt
+++ b/ext/dba/tests/dba003.phpt
@@ -2,12 +2,12 @@
DBA Insert/Replace/Fetch Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
dba_insert("key1", "This is a test insert", $db_file);
diff --git a/ext/dba/tests/dba004.phpt b/ext/dba/tests/dba004.phpt
index 3b1f29c7d..42da1c64b 100644
--- a/ext/dba/tests/dba004.phpt
+++ b/ext/dba/tests/dba004.phpt
@@ -2,12 +2,12 @@
DBA Multiple Insert/Fetch Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
dba_insert("key1", "Content String 1", $db_file);
diff --git a/ext/dba/tests/dba005.phpt b/ext/dba/tests/dba005.phpt
index 5a933c48f..3e7e58086 100644
--- a/ext/dba/tests/dba005.phpt
+++ b/ext/dba/tests/dba005.phpt
@@ -2,12 +2,12 @@
DBA FirstKey/NextKey Loop Test With 5 Items
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
dba_insert("key1", "Content String 1", $db_file);
diff --git a/ext/dba/tests/dba006.phpt b/ext/dba/tests/dba006.phpt
index efa36a5d0..f6177b0b9 100644
--- a/ext/dba/tests/dba006.phpt
+++ b/ext/dba/tests/dba006.phpt
@@ -2,12 +2,12 @@
DBA FirstKey/NextKey with 2 deletes
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
dba_insert("key1", "Content String 1", $db_file);
@@ -34,4 +34,4 @@ DBA FirstKey/NextKey with 2 deletes
?>
--EXPECTF--
database handler: %s
-3NYNYY \ No newline at end of file
+3NYNYY
diff --git a/ext/dba/tests/dba007.phpt b/ext/dba/tests/dba007.phpt
index cc84a729c..0f30932fc 100644
--- a/ext/dba/tests/dba007.phpt
+++ b/ext/dba/tests/dba007.phpt
@@ -2,13 +2,13 @@
DBA Multiple File Creation Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
if (!function_exists('dba_list')) die('skip dba_list() not available');
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
$db_file1 = dirname(__FILE__).'/test1.dbm';
$db_file2 = dirname(__FILE__).'/test2.dbm';
diff --git a/ext/dba/tests/dba008.phpt b/ext/dba/tests/dba008.phpt
index 84a47ba08..8fde8ff3f 100644
--- a/ext/dba/tests/dba008.phpt
+++ b/ext/dba/tests/dba008.phpt
@@ -2,12 +2,12 @@
DBA magic_quotes_runtime Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
ini_set('magic_quotes_runtime', 0);
diff --git a/ext/dba/tests/dba009.phpt b/ext/dba/tests/dba009.phpt
index 50a50c6bd..b4d8308e8 100755
--- a/ext/dba/tests/dba009.phpt
+++ b/ext/dba/tests/dba009.phpt
@@ -2,12 +2,12 @@
DBA dba_popen Test
--SKIPIF--
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
print("info $HND handler used");
?>
--FILE--
<?php
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
if (($db=dba_popen($db_file, "n", $handler))!==FALSE) {
echo "Opened\n";
diff --git a/ext/dba/tests/dba_cdb.phpt b/ext/dba/tests/dba_cdb.phpt
index f3bf7975e..0b7559648 100644
--- a/ext/dba/tests/dba_cdb.phpt
+++ b/ext/dba/tests/dba_cdb.phpt
@@ -3,14 +3,14 @@ DBA CDB handler test
--SKIPIF--
<?php
$handler = 'cdb';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die('info CDB does not support replace or delete');
?>
--FILE--
<?php
$handler = 'cdb';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_cdb_make.phpt b/ext/dba/tests/dba_cdb_make.phpt
index bb41e82fb..b7311f1dd 100644
--- a/ext/dba/tests/dba_cdb_make.phpt
+++ b/ext/dba/tests/dba_cdb_make.phpt
@@ -5,13 +5,13 @@ magic_quotes_runtime=1
--SKIPIF--
<?php
$handler = 'cdb_make';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
die('info CDB_MAKE does not support reading');
?>
--FILE--
<?php
$handler = 'cdb_make';
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
echo "database handler: $handler\n";
// print md5 checksum of test.cdb which is generated by cdb_make program
var_dump(md5_file(dirname(__FILE__).'/test.cdb'));
diff --git a/ext/dba/tests/dba_cdb_read.phpt b/ext/dba/tests/dba_cdb_read.phpt
index a0fbe7bcc..71575f5d8 100644
--- a/ext/dba/tests/dba_cdb_read.phpt
+++ b/ext/dba/tests/dba_cdb_read.phpt
@@ -3,7 +3,7 @@ DBA CDB handler test (read only)
--SKIPIF--
<?php
$handler = 'cdb_make';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
@@ -62,4 +62,4 @@ database handler: cdb
#1122
?1212314
#1212314
-=1231324 \ No newline at end of file
+=1231324
diff --git a/ext/dba/tests/dba_db1.phpt b/ext/dba/tests/dba_db1.phpt
index 983954b50..a24600350 100755
--- a/ext/dba/tests/dba_db1.phpt
+++ b/ext/dba/tests/dba_db1.phpt
@@ -3,13 +3,13 @@ DBA DB1 handler test
--SKIPIF--
<?php
$handler = 'db1';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'db1';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_db2.phpt b/ext/dba/tests/dba_db2.phpt
index bcc5a9479..89d8a926e 100644
--- a/ext/dba/tests/dba_db2.phpt
+++ b/ext/dba/tests/dba_db2.phpt
@@ -3,13 +3,13 @@ DBA DB2 handler test
--SKIPIF--
<?php
$handler = 'db2';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'db2';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_db3.phpt b/ext/dba/tests/dba_db3.phpt
index c6d04cf02..257c88217 100644
--- a/ext/dba/tests/dba_db3.phpt
+++ b/ext/dba/tests/dba_db3.phpt
@@ -3,13 +3,13 @@ DBA DB3 handler test
--SKIPIF--
<?php
$handler = 'db3';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'db3';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_db4.phpt b/ext/dba/tests/dba_db4.phpt
index fcf089a1e..2c2a7a694 100644
--- a/ext/dba/tests/dba_db4.phpt
+++ b/ext/dba/tests/dba_db4.phpt
@@ -3,13 +3,13 @@ DBA DB4 handler test
--SKIPIF--
<?php
$handler = 'db4';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'db4';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_dbm.phpt b/ext/dba/tests/dba_dbm.phpt
index fdd7b375f..dd1fe1e31 100644
--- a/ext/dba/tests/dba_dbm.phpt
+++ b/ext/dba/tests/dba_dbm.phpt
@@ -3,13 +3,13 @@ DBA DBM handler test
--SKIPIF--
<?php
$handler = 'dbm';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'dbm';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_flatfile.phpt b/ext/dba/tests/dba_flatfile.phpt
index 2e32b8a32..a85472bbe 100644
--- a/ext/dba/tests/dba_flatfile.phpt
+++ b/ext/dba/tests/dba_flatfile.phpt
@@ -3,13 +3,13 @@ DBA FlatFile handler test
--SKIPIF--
<?php
$handler = 'flatfile';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'flatfile';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_gdbm.phpt b/ext/dba/tests/dba_gdbm.phpt
index f9b3e3c60..33d7d2061 100644
--- a/ext/dba/tests/dba_gdbm.phpt
+++ b/ext/dba/tests/dba_gdbm.phpt
@@ -3,14 +3,14 @@ DBA GDBM handler test
--SKIPIF--
<?php
$handler = 'gdbm';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'gdbm';
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
$lock_flag = ''; // lock in library
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/dba_handler.inc';
// Read during write is system dependant. Important is that there is no deadlock
?>
diff --git a/ext/dba/tests/dba_inifile.phpt b/ext/dba/tests/dba_inifile.phpt
index 9511a8bb4..81ab73879 100644
--- a/ext/dba/tests/dba_inifile.phpt
+++ b/ext/dba/tests/dba_inifile.phpt
@@ -3,13 +3,13 @@ DBA INIFILE handler test
--SKIPIF--
<?php
$handler = 'inifile';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'inifile';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_ndbm.phpt b/ext/dba/tests/dba_ndbm.phpt
index f7955c581..b0f5542de 100644
--- a/ext/dba/tests/dba_ndbm.phpt
+++ b/ext/dba/tests/dba_ndbm.phpt
@@ -3,13 +3,13 @@ DBA NDBM handler test
--SKIPIF--
<?php
$handler = 'ndbm';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'ndbm';
- require_once('test.inc');
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/test.inc';
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECT--
diff --git a/ext/dba/tests/dba_qdbm.phpt b/ext/dba/tests/dba_qdbm.phpt
index a7c9ab69e..ef216d925 100755
--- a/ext/dba/tests/dba_qdbm.phpt
+++ b/ext/dba/tests/dba_qdbm.phpt
@@ -3,14 +3,14 @@ DBA QDBM handler test
--SKIPIF--
<?php
$handler = 'qdbm';
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
?>
--FILE--
<?php
$handler = 'qdbm';
- require_once('test.inc');
+ require_once dirname(__FILE__) .'/test.inc';
$lock_flag = ''; // lock in library
- require_once('dba_handler.inc');
+ require_once dirname(__FILE__) .'/dba_handler.inc';
?>
===DONE===
--EXPECTF--
diff --git a/ext/dba/tests/test.inc b/ext/dba/tests/test.inc
index 04f954541..7c4e207b8 100644
--- a/ext/dba/tests/test.inc
+++ b/ext/dba/tests/test.inc
@@ -1,7 +1,7 @@
<?php
- require_once('skipif.inc');
+ require_once dirname(__FILE__) .'/skipif.inc';
$lock_flag = 'l';
- $db_filename = $db_file = dirname(__FILE__).'/test0.dbm';
+ $db_filename = $db_file = dirname(__FILE__) .'/test0.dbm';
@unlink($db_filename);
@unlink($db_filename.'.lck');
?>