summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xext/pdo/pdo_dbh.c15
-rwxr-xr-xext/pdo/php_pdo_int.h1
2 files changed, 13 insertions, 3 deletions
diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c
index 2e814ed99c..9f2099954c 100755
--- a/ext/pdo/pdo_dbh.c
+++ b/ext/pdo/pdo_dbh.c
@@ -196,7 +196,7 @@ static PHP_FUNCTION(dbh_constructor)
}
colon = strchr(data_source, ':');
if (!colon) {
- zend_throw_exception_ex(php_pdo_get_exception(), PDO_ERR_SYNTAX TSRMLS_CC, "invalid data source name");
+ zend_throw_exception_ex(php_pdo_get_exception(), PDO_ERR_SYNTAX TSRMLS_CC, "invalid data source name (via uri)");
ZVAL_NULL(object);
return;
}
@@ -575,7 +575,7 @@ static PHP_METHOD(PDO, query)
static PHP_METHOD(PDO, exec) /* FIXME: nuke on release */
{
php_error_docref(NULL TSRMLS_CC, E_WARNING, "This is name deprecated, use PDO::query instead");
- PHP_FN(PDO_exec)(INTERNAL_FUNCTION_PARAM_PASSTHRU);
+ PHP_FN(PDO_query)(INTERNAL_FUNCTION_PARAM_PASSTHRU);
}
/* }}} */
@@ -777,10 +777,19 @@ static HashTable *dbh_get_properties(zval *object TSRMLS_DC)
return NULL;
}
-static union _zend_function *dbh_method_get(zval *object, char *method_name, int method_len TSRMLS_DC)
+static union _zend_function *dbh_method_get(
+#if PHP_API_VERSION >= 20041225
+ zval **object_pp,
+#else
+ zval *object,
+#endif
+ char *method_name, int method_len TSRMLS_DC)
{
zend_function *fbc;
char *lc_method_name;
+#if PHP_API_VERSION >= 20041225
+ zval *object = *object_pp;
+#endif
pdo_dbh_t *dbh = zend_object_store_get_object(object TSRMLS_CC);
lc_method_name = emalloc(method_len + 1);
diff --git a/ext/pdo/php_pdo_int.h b/ext/pdo/php_pdo_int.h
index 8e00989567..51c0fef392 100755
--- a/ext/pdo/php_pdo_int.h
+++ b/ext/pdo/php_pdo_int.h
@@ -45,6 +45,7 @@ extern zend_class_entry *pdo_row_ce;
void pdo_row_free_storage(zend_object *object TSRMLS_DC);
extern zend_object_handlers pdo_row_object_handlers;
+zend_object_iterator *php_pdo_dbstmt_iter_get(zend_class_entry *ce, zval *object TSRMLS_DC);
extern pdo_driver_t *pdo_find_driver(const char *name, int namelen);