mirror of
https://github.com/phpredis/phpredis.git
synced 2026-06-19 07:35:31 +00:00
Use ZSTR_VAL and ZSTR_LEN macroses to access zend_string fields
This commit is contained in:
+2
-2
@@ -590,7 +590,7 @@ ra_index_keys(zval *z_pairs, zval *z_redis TSRMLS_DC) {
|
||||
#endif
|
||||
|
||||
if (zkey) {
|
||||
ZVAL_STRINGL(z_new, zkey->val, zkey->len);
|
||||
ZVAL_STRINGL(z_new, ZSTR_VAL(zkey), ZSTR_LEN(zkey));
|
||||
} else {
|
||||
ZVAL_LONG(z_new, idx);
|
||||
}
|
||||
@@ -898,7 +898,7 @@ ra_move_zset(const char *key, int key_len, zval *z_from, zval *z_to, long ttl TS
|
||||
|
||||
/* add value */
|
||||
if (zkey) {
|
||||
ZVAL_STRINGL(&z_zadd_args[i+1], zkey->val, zkey->len);
|
||||
ZVAL_STRINGL(&z_zadd_args[i+1], ZSTR_VAL(zkey), ZSTR_LEN(zkey));
|
||||
} else {
|
||||
ZVAL_LONG(&z_zadd_args[i+1], (long)idx);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user