summaryrefslogtreecommitdiff
path: root/xcache
diff options
context:
space:
mode:
authorXuefer <xuefer@gmail.com>2013-07-13 04:24:58 +0000
committerXuefer <xuefer@gmail.com>2013-07-13 04:24:58 +0000
commitb6c66205a7d94bf69b5f63cd2dd097c503e64989 (patch)
tree39ab8a825860629af268c318265ec7965cf5caa3 /xcache
parentfea60080b7c5cd76391c50c98410d4c7959920c5 (diff)
downloadxcache-b6c66205a7d94bf69b5f63cd2dd097c503e64989.tar.gz
xcache-b6c66205a7d94bf69b5f63cd2dd097c503e64989.zip
Decompiler, disassembler: fix catch for different PHP version; fetch hack is not necessary for PHP5.4+; update for ?: operator
git-svn-id: svn://svn.lighttpd.net/xcache/trunk@1306 c26eb9a1-5813-0410-bd6c-c2e55f420ca7
Diffstat (limited to 'xcache')
-rw-r--r--xcache/xc_opcode_spec.c4
-rw-r--r--xcache/xc_opcode_spec_def.h8
2 files changed, 4 insertions, 8 deletions
diff --git a/xcache/xc_opcode_spec.c b/xcache/xc_opcode_spec.c
index b563181..5043506 100644
--- a/xcache/xc_opcode_spec.c
+++ b/xcache/xc_opcode_spec.c
@@ -5,6 +5,10 @@
/* {{{ opcode_spec */
#define OPSPEC(ext, op1, op2, res) { OPSPEC_##ext, OPSPEC_##op1, OPSPEC_##op2, OPSPEC_##res },
#define OPSPEC_VAR_2 OPSPEC_STD
+#ifdef ZEND_ENGINE_2_4
+#undef OPSPEC_FETCH
+#define OPSPEC_FETCH OPSPEC_STD
+#endif
#include "xc_opcode_spec_def.h"
zend_uchar xc_get_opcode_spec_count()
diff --git a/xcache/xc_opcode_spec_def.h b/xcache/xc_opcode_spec_def.h
index 13dd0f1..1ab75a5 100644
--- a/xcache/xc_opcode_spec_def.h
+++ b/xcache/xc_opcode_spec_def.h
@@ -79,11 +79,7 @@ static const xc_opcode_spec_t xc_opcode_spec[] = {
OPSPEC( UNUSED, STD, INCLUDE, VAR) /* 73 INCLUDE_OR_EVAL */
#ifdef ZEND_ENGINE_2_1
/* php 5.1 and up */
-# ifdef ZEND_ENGINE_2_4
- OPSPEC( UNUSED, STD, STD, UNUSED) /* 74 UNSET_VAR */
-# else
OPSPEC( UNUSED, STD, FETCH, UNUSED) /* 74 UNSET_VAR */
-# endif
OPSPEC( STD, STD, STD, UNUSED) /* 75 UNSET_DIM */
OPSPEC( STD, STD, STD, UNUSED) /* 76 UNSET_OBJ */
OPSPEC( BIT, STD, OPLINE, VAR) /* 77 FE_RESET */
@@ -153,11 +149,7 @@ static const xc_opcode_spec_t xc_opcode_spec[] = {
#else
OPSPEC( UNUSED, UCLASS, STD, UNUSED) /* 113 INIT_STATIC_METHOD_CALL */
#endif
-#ifdef ZEND_ENGINE_2_4
- OPSPEC( ISSET, STD, STD, TMP) /* 114 ISSET_ISEMPTY_VAR */
-#else
OPSPEC( ISSET, STD, FETCH, TMP) /* 114 ISSET_ISEMPTY_VAR */
-#endif
OPSPEC( ISSET, STD, STD, TMP) /* 115 ISSET_ISEMPTY_DIM_OBJ */
OPSPEC( UNUSED, CLASS, STD, UNUSED) /* 116 IMPORT_FUNCTION */