diff options
Diffstat (limited to 'Zend/zend_operators.c')
-rw-r--r-- | Zend/zend_operators.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index 57527df07..f75320a73 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_operators.c,v 1.193.2.8 2004/11/29 09:39:57 derick Exp $ */ +/* $Id: zend_operators.c,v 1.193.2.9 2005/04/08 14:36:39 helly Exp $ */ #include <ctype.h> @@ -1284,24 +1284,26 @@ static inline void zend_free_obj_get_result(zval *op, int free_op) } #define COMPARE_RETURN_AND_FREE(retval) \ - zend_free_obj_get_result(op1, free_op1); \ - zend_free_obj_get_result(op2, free_op2); \ + zend_free_obj_get_result(op1_orig, free_op1); \ + zend_free_obj_get_result(op2_orig, free_op2); \ return retval; ZEND_API int compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) { zval op1_copy, op2_copy; zend_bool free_op1 = 0, free_op2 = 0; + zval *op1_orig, *op2_orig; if (op1->type == IS_OBJECT && Z_OBJ_HT_P(op1)->get) { op1 = Z_OBJ_HT_P(op1)->get(op1 TSRMLS_CC); free_op1 = 1; } + op1_orig = op1; if (op2->type == IS_OBJECT && Z_OBJ_HT_P(op2)->get) { op2 = Z_OBJ_HT_P(op2)->get(op2 TSRMLS_CC); free_op2 = 1; } - + op2_orig = op2; if ((op1->type == IS_NULL && op2->type == IS_STRING) || (op2->type == IS_NULL && op1->type == IS_STRING)) { |