diff options
-rw-r--r-- | README.markdown | 2 | ||||
-rw-r--r-- | common.h | 1 | ||||
-rw-r--r-- | redis_commands.c | 6 |
3 files changed, 5 insertions, 4 deletions
diff --git a/README.markdown b/README.markdown index c30fd2d3..4840f4cd 100644 --- a/README.markdown +++ b/README.markdown @@ -1,6 +1,6 @@ # PhpRedis -[![Build Status](https://travis-ci.org/phpredis/phpredis.svg?branch=develop)](https://travis-ci.org/phpredis/phpredis) +[![Build Status](https://travis-ci.com/phpredis/phpredis.svg?branch=develop)](https://travis-ci.com/phpredis/phpredis) [![Coverity Scan Build Status](https://scan.coverity.com/projects/13205/badge.svg)](https://scan.coverity.com/projects/phpredis-phpredis) [![PHP version from Travis config](https://img.shields.io/travis/php-v/phpredis/phpredis/develop)](https://img.shields.io/travis/php-v/phpredis/phpredis/develop) @@ -4,6 +4,7 @@ #ifndef REDIS_COMMON_H #define REDIS_COMMON_H +#define PHPREDIS_CTX_PTR ((void *)0xDEADC0DE) #define PHPREDIS_NOTUSED(v) ((void)v) #include "zend_llist.h" diff --git a/redis_commands.c b/redis_commands.c index 991ea1ff..06e352cc 100644 --- a/redis_commands.c +++ b/redis_commands.c @@ -667,7 +667,7 @@ redis_zdiff_cmd(INTERNAL_FUNCTION_PARAMETERS, RedisSock *redis_sock, if (withscores) { REDIS_CMD_APPEND_SSTR_STATIC(&cmdstr, "WITHSCORES"); - *ctx = redis_sock; + *ctx = PHPREDIS_CTX_PTR; } *cmd = cmdstr.c; @@ -785,7 +785,7 @@ redis_zinterunion_cmd(INTERNAL_FUNCTION_PARAMETERS, RedisSock *redis_sock, if (withscores) { REDIS_CMD_APPEND_SSTR_STATIC(&cmdstr, "WITHSCORES"); - *ctx = redis_sock; + *ctx = PHPREDIS_CTX_PTR; } *cmd = cmdstr.c; @@ -1621,7 +1621,7 @@ int redis_set_cmd(INTERNAL_FUNCTION_PARAMETERS, RedisSock *redis_sock, redis_cmd_append_sstr(&cmdstr, "KEEPTTL", 7); if (get) { REDIS_CMD_APPEND_SSTR_STATIC(&cmdstr, "GET"); - *ctx = redis_sock; + *ctx = PHPREDIS_CTX_PTR; } /* Push command and length to the caller */ |