summaryrefslogtreecommitdiff
path: root/ext/mysqlnd/mysqlnd_wireprotocol.c
diff options
context:
space:
mode:
authorAndrey Hristov <andrey@php.net>2010-02-01 16:12:03 +0000
committerAndrey Hristov <andrey@php.net>2010-02-01 16:12:03 +0000
commitbefab3e8c380796a7c92d661a3abe93427069940 (patch)
tree23d5268002131c1abb4908368c59cfef2a12ac80 /ext/mysqlnd/mysqlnd_wireprotocol.c
parent6d913a02724aa142cc60c56ef606cbca09a673be (diff)
downloadphp-git-befab3e8c380796a7c92d661a3abe93427069940.tar.gz
Fix a bug in mysqlnd where a pointer was not incremented
and thus wrong data was saved MYSQLND_FIELD::db. However, this wasn't caught because there is no code in mysql/mysqli/pdo_mysql which reads that field of the structure. The problem was found during code review.
Diffstat (limited to 'ext/mysqlnd/mysqlnd_wireprotocol.c')
-rw-r--r--ext/mysqlnd/mysqlnd_wireprotocol.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c
index c2ceec6bb5..11a1191ee5 100644
--- a/ext/mysqlnd/mysqlnd_wireprotocol.c
+++ b/ext/mysqlnd/mysqlnd_wireprotocol.c
@@ -957,6 +957,7 @@ php_mysqlnd_rset_field_read(void *_packet, MYSQLND *conn TSRMLS_DC)
len = meta->db_length;
meta->db = memcpy(root_ptr, meta->db, len);
*(root_ptr + len) = '\0';
+ root_ptr++;
}
if (meta->table && meta->table != mysqlnd_empty_string) {