From 05cb73fe991dadd49eecd2a0bea7dc66dcb80e28 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Thu, 29 Sep 2011 15:24:59 +0100 Subject: [PATCH] More PHP 5.2 compatibility. --- twig.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/twig.c b/twig.c index 690ce80..2cd88b3 100644 --- a/twig.c +++ b/twig.c @@ -157,8 +157,8 @@ zval *TWIG_GET_ARRAYOBJECT_ELEMENT(zval *object, zval *offset) zval_ptr_dtor(&offset); - if (UNEXPECTED(!retval)) { - if (UNEXPECTED(!EG(exception))) { + if (!retval) { + if (!EG(exception)) { zend_error_noreturn(E_ERROR, "Undefined offset for object of type %s used as array", ce->name); } return NULL; @@ -180,8 +180,8 @@ int TWIG_ISSET_ARRAYOBJECT_ELEMENT(zval *object, zval *offset) zval_ptr_dtor(&offset); - if (UNEXPECTED(!retval)) { - if (UNEXPECTED(!EG(exception))) { + if (!retval) { + if (!EG(exception)) { zend_error_noreturn(E_ERROR, "Undefined offset for object of type %s used as array", ce->name); } return 0; -- 1.7.2.5