diff options
author | defender-11 <guchangsheng@hotmail.com> | 2021-01-22 19:52:55 +0300 |
---|---|---|
committer | defender-11 <guchangsheng@hotmail.com> | 2021-01-22 19:52:55 +0300 |
commit | c61396c4898f618373cbbd7c6adc7faf2746f953 (patch) | |
tree | 7f8abd3cab3f191988e7a9e0c45816b5a38ae357 /redis_array_impl.c | |
parent | e9ba9ff12e74c3483f2cb54b7fc9fb7250829a2a (diff) |
Fixed#1895
Diffstat (limited to 'redis_array_impl.c')
-rw-r--r-- | redis_array_impl.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/redis_array_impl.c b/redis_array_impl.c index e34d43d1..37a84ba7 100644 --- a/redis_array_impl.c +++ b/redis_array_impl.c @@ -494,7 +494,11 @@ ra_find_node(RedisArray *ra, const char *key, int key_len, int *out_pos) void *ctx = emalloc(ops->context_size); unsigned char *digest = emalloc(ops->digest_size); +#if PHP_VERSION_ID >= 80100 + ops->hash_init(ctx,NULL); +#else ops->hash_init(ctx); +#endif ops->hash_update(ctx, (const unsigned char *)ZSTR_VAL(out), ZSTR_LEN(out)); ops->hash_final(digest, ctx); |