Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpredis/phpredis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavlo Yatsukhnenko <yatsukhnenko@gmail.com>2019-02-22 10:09:49 +0300
committermichael-grunder <michael.grunder@gmail.com>2019-03-19 23:05:40 +0300
commitc6519dda47ed29f7130959d3ed7c74ff11e6ec62 (patch)
tree235546632fe47638817e4cb7d940b19499300226 /library.c
parentf9016f1bfb4e6350efe2f91d724d74fa482136bd (diff)
Issue #1514
`sizeof(void *)` isn't standard so change it to `sizeof(char *)`
Diffstat (limited to 'library.c')
-rw-r--r--library.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/library.c b/library.c
index 2b308ea5..dfc6a876 100644
--- a/library.c
+++ b/library.c
@@ -1812,8 +1812,8 @@ redis_sock_disconnect(RedisSock *redis_sock, int force TSRMLS_DC)
zend_resource *le = zend_hash_find_ptr(&EG(persistent_list), persistent_id);
if (!le) {
zend_llist *l = pecalloc(1, sizeof(*l) + sizeof(*le), 1);
- zend_llist_init(l, sizeof(void *), NULL, 1);
- le = (void *)l + sizeof(*l);
+ zend_llist_init(l, sizeof(php_stream *), NULL, 1);
+ le = (zend_resource *)((char *)l + sizeof(*l));
le->type = le_redis_pconnect;
le->ptr = l;
zend_hash_str_update_mem(&EG(persistent_list), ZSTR_VAL(persistent_id), ZSTR_LEN(persistent_id), le, sizeof(*le));