Show
Ignore:
Timestamp:
06/19/08 18:01:31 (6 months ago)
Author:
bart
Message:

Remove support for all php versions older than php 5.1

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • eaccelerator/trunk/ea_dasm.c

    r286 r344  
    9999        "FETCH_GLOBAL",                         /* 0 */ 
    100100        "FETCH_LOCAL",                          /* 1 */ 
    101         "FETCH_STATIC"                          /* 2 */ 
    102 #ifdef ZEND_ENGINE_2 
    103         , 
    104         "FETCH_STATIC_MEMBER"           /* 3 */ 
    105 #ifdef ZEND_ENGINE_2_1 
    106     , 
     101        "FETCH_STATIC",                         /* 2 */ 
     102        "FETCH_STATIC_MEMBER",          /* 3 */ 
    107103    "UNKNOWN 1"                 /* 4 */ 
    108 #endif 
    109 #endif 
    110104}; 
    111105/* }}} */ 
     
    272266                                        buf[0] = '\0'; 
    273267                } 
    274 #ifdef ZEND_ENGINE_2 
    275268            } else if ((op->ops & EXT_MASK) == EXT_ASSIGN) { 
    276269                if (opline->extended_value == ZEND_ASSIGN_OBJ) { 
     
    281274                                        buf[0] = '\0'; 
    282275                } 
    283 #ifndef ZEND_ENGINE_2_1 
    284             } else if (opline->opcode == ZEND_UNSET_DIM_OBJ) { 
    285                 if (opline->extended_value == ZEND_UNSET_DIM) { 
    286                     snprintf(buf, sizeof(buf), "ZEND_UNSET_DIM"); 
    287                 } else if (opline->extended_value == ZEND_UNSET_OBJ) { 
    288                     snprintf(buf, sizeof(buf), "ZEND_UNSET_OBJ"); 
    289                 } else { 
    290                                         buf[0] = '\0'; 
    291                 } 
    292 #endif 
    293 #endif 
    294276            } else if (opline->extended_value != 0) { 
    295277                snprintf(buf, sizeof(buf), "%ld", opline->extended_value); 
     
    301283            /* op1 */ 
    302284            zval_used = 0; 
    303 #ifdef ZEND_ENGINE_2_1 
    304285            if (opline->op1.op_type == IS_CV) { 
    305286                snprintf(buf, sizeof(buf), "$cv%u(%s)", opline->op1.u.var, op_array->vars[opline->op1.u.var].name); 
    306             } else 
    307 #endif 
    308             if ((op->ops & OP1_MASK) == OP1_OPLINE) { 
     287            } else if ((op->ops & OP1_MASK) == OP1_OPLINE) { 
    309288                snprintf(buf, sizeof(buf), "opline(%d)", opline->op1.u.opline_num); 
    310 #ifdef ZEND_ENGINE_2 
    311289            } else if ((op->ops & OP1_MASK) == OP1_JMPADDR) { 
    312290                snprintf(buf, sizeof(buf), "opline(%u)", (unsigned int)(opline->op1.u.jmp_addr - op_array->opcodes)); 
     
    319297                    snprintf(buf, sizeof(buf), "$class%u", VAR_NUM(opline->op1.u.var)); 
    320298                } 
    321 #endif 
    322299            } else if ((op->ops & OP1_MASK) == OP1_BRK) { 
    323300                if (opline->op1.u.opline_num != -1 && opline->op2.op_type == IS_CONST && opline->op2.u.constant.type == IS_LONG) { 
     
    380357            /* op2 */ 
    381358            zval_used = 0; 
    382 #ifdef ZEND_ENGINE_2_1 
    383359            if (opline->op2.op_type == IS_CV) { 
    384360                snprintf(buf, sizeof(buf), "$cv%u(%s)", opline->op2.u.var, op_array->vars[opline->op2.u.var].name); 
    385             } else  
    386 #endif 
    387                         if ((op->ops & OP2_MASK) == OP2_OPLINE) { 
     361            } else if ((op->ops & OP2_MASK) == OP2_OPLINE) { 
    388362                                snprintf(buf, sizeof(buf), "opline(%d)", opline->op2.u.opline_num); 
    389 #ifdef ZEND_ENGINE_2 
    390363                        } else if ((op->ops & OP2_MASK) == OP2_JMPADDR) { 
    391364                                snprintf(buf, sizeof(buf), "opline(%u)", (unsigned int) (opline->op2.u.jmp_addr - op_array->opcodes)); 
    392365                        } else if ((op->ops & OP2_MASK) == OP2_CLASS) { 
    393366                                snprintf(buf, sizeof(buf), "$class%u", VAR_NUM(opline->op2.u.var)); 
    394 #endif 
    395367                        } else if ((op->ops & OP2_MASK) == OP2_VAR) { 
    396368                                snprintf(buf, sizeof(buf), "$var%u", VAR_NUM(opline->op2.u.var)); 
    397369                        } else if ((op->ops & OP2_MASK) == OP2_FETCH) { 
    398 #ifdef ZEND_ENGINE_2 
    399370                                if (opline->op2.u.EA.type == ZEND_FETCH_STATIC_MEMBER) { 
    400371                                        snprintf(buf, sizeof(buf), "%s $class%u", fetchtypename[opline->op2.u.EA.type], VAR_NUM(opline->op2.u.var)); 
     
    402373                                        snprintf(buf, sizeof(buf), "%s", fetchtypename[opline->op2.u.EA.type]); 
    403374                                } 
    404 #else 
    405                                 strncpy(buf, fetchtypename[opline->op2.u.fetch_type], sizeof(buf)); 
    406 #endif 
    407375                        } else if ((op->ops & OP2_MASK) == OP2_INCLUDE) { 
    408376                                if (opline->op2.u.constant.value.lval == ZEND_EVAL) { 
     
    449417            /* result */ 
    450418            zval_used = 0; 
    451 #ifdef ZEND_ENGINE_2_1 
    452419            if (opline->result.op_type == IS_CV) { 
    453420                snprintf(buf, sizeof(buf), "$cv%u(%s)", opline->result.u.var, op_array->vars[opline->result.u.var].name); 
    454421            } else  
    455 #endif  
    456422                        switch (op->ops & RES_MASK) { 
    457423                            case RES_STD: