summaryrefslogtreecommitdiff
path: root/ext/pdo/pdo_stmt.c
diff options
context:
space:
mode:
authorWez Furlong <wez@php.net>2005-07-08 17:00:28 +0000
committerWez Furlong <wez@php.net>2005-07-08 17:00:28 +0000
commit38a02b62446cdb60037f67eb0f2b5c4d8c3039a6 (patch)
treed0cdf7e99650c4dd3dc9e6b18caec76ca2a556fa /ext/pdo/pdo_stmt.c
parent2301d93156c60ad44bdb4d42bcddb8a3d9844d22 (diff)
downloadphp-git-38a02b62446cdb60037f67eb0f2b5c4d8c3039a6.tar.gz
For named-parameter-to-named-parameter rewrites, we need to map the original
names to the new names.
Diffstat (limited to 'ext/pdo/pdo_stmt.c')
-rwxr-xr-xext/pdo/pdo_stmt.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c
index 4f765ffa20..51770d3130 100755
--- a/ext/pdo/pdo_stmt.c
+++ b/ext/pdo/pdo_stmt.c
@@ -86,6 +86,12 @@ static inline int rewrite_name_to_position(pdo_stmt_t *stmt, struct pdo_bound_pa
* driver */
char *name;
int position = 0;
+
+ if (stmt->named_rewrite_template) {
+ /* this is not an error here */
+ return 1;
+ }
+
zend_hash_internal_pointer_reset(stmt->bound_param_map);
while (SUCCESS == zend_hash_get_current_data(stmt->bound_param_map, (void**)&name)) {
if (strcmp(name, param->name)) {