summaryrefslogtreecommitdiff
path: root/ext/mysqli/mysqli.c
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2017-12-07 19:24:55 +0300
committerDmitry Stogov <dmitry@zend.com>2017-12-07 19:24:55 +0300
commit6a9d2b2190923bfbc7b7caa1462ba95965a1b991 (patch)
tree26d1695b07a29a873e5fcd74cd4af47c89454f78 /ext/mysqli/mysqli.c
parentc890d469fab27500f0fa1070dccb16b36aa8be76 (diff)
downloadphp-git-6a9d2b2190923bfbc7b7caa1462ba95965a1b991.tar.gz
Cleanup type conversion
Diffstat (limited to 'ext/mysqli/mysqli.c')
-rw-r--r--ext/mysqli/mysqli.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c
index c8d8bd44f5..97660f0022 100644
--- a/ext/mysqli/mysqli.c
+++ b/ext/mysqli/mysqli.c
@@ -307,8 +307,7 @@ zval *mysqli_read_property(zval *object, zval *member, int type, void **cache_sl
obj = Z_MYSQLI_P(object);
if (Z_TYPE_P(member) != IS_STRING) {
- ZVAL_COPY(&tmp_member, member);
- convert_to_string(&tmp_member);
+ ZVAL_STR(&tmp_member, zval_get_string_func(member));
member = &tmp_member;
}
@@ -342,8 +341,7 @@ void mysqli_write_property(zval *object, zval *member, zval *value, void **cache
mysqli_prop_handler *hnd = NULL;
if (Z_TYPE_P(member) != IS_STRING) {
- ZVAL_COPY(&tmp_member, member);
- convert_to_string(&tmp_member);
+ ZVAL_STR(&tmp_member, zval_get_string_func(member));
member = &tmp_member;
}