Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Avoiding conditional directives that split up statements. #706

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 14, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions redis_commands.c
Original file line number Diff line number Diff line change
Expand Up @@ -2913,7 +2913,7 @@ void redis_setoption_handler(INTERNAL_FUNCTION_PARAMETERS,
{
long option, val_long;
char *val_str;
int val_len;
int val_len, test_val;
struct timeval read_tv;

if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &option,
Expand All @@ -2925,11 +2925,11 @@ void redis_setoption_handler(INTERNAL_FUNCTION_PARAMETERS,
switch(option) {
case REDIS_OPT_SERIALIZER:
val_long = atol(val_str);
if(val_long == REDIS_SERIALIZER_NONE
test_val = val_long == REDIS_SERIALIZER_NONE || val_long == REDIS_SERIALIZER_PHP;
#ifdef HAVE_REDIS_IGBINARY
|| val_long == REDIS_SERIALIZER_IGBINARY
test_val = test_val || val_long == REDIS_SERIALIZER_IGBINARY;
#endif
|| val_long == REDIS_SERIALIZER_PHP)
if(test_val)
{
redis_sock->serializer = val_long;
RETURN_TRUE;
Expand Down