From 15bc0173ef7b06ef16e477e8b12c3eac5bcf2abc Mon Sep 17 00:00:00 2001 From: Arnaud Le Blanc Date: Wed, 3 Jul 2019 18:54:11 +0200 Subject: [PATCH] Fix PHP 5.6 build --- rdkafka.c | 4 ++-- travis.sh | 2 +- zeval.h | 4 ++++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/rdkafka.c b/rdkafka.c index 74bc2b1..fd9c9d1 100644 --- a/rdkafka.c +++ b/rdkafka.c @@ -567,8 +567,8 @@ PHP_METHOD(RdKafka__Kafka, queryWatermarkOffsets) return; } - ZVAL_DEREF(lowResult); - ZVAL_DEREF(highResult); + ZEVAL_DEREF(lowResult); + ZEVAL_DEREF(highResult); intern = get_kafka_object(getThis() TSRMLS_CC); if (!intern) { diff --git a/zeval.h b/zeval.h index 62d445c..74c2711 100644 --- a/zeval.h +++ b/zeval.h @@ -31,6 +31,8 @@ typedef zval zeval; #define ZEVAL_DUP_C #define ZEVAL_DUP_CC +#define ZEVAL_DEREF(v) ZVAL_DEREF(v) + /***************************************************************************/ #elif defined(ZEND_ENGINE_2) @@ -59,6 +61,8 @@ typedef zval* zeval; #define ZEVAL_DUP_C 1 #define ZEVAL_DUP_CC , 1 +#define ZEVAL_DEREF(v) (v) + /***************************************************************************/ #else # error "Unknown Zend Engine version"