Fixed comilation warnings

This commit is contained in:
Dmitry Stogov 2008-01-24 18:07:45 +00:00
parent c09d8d931f
commit d90ebc65a6
5 changed files with 20 additions and 21 deletions

View File

@ -523,9 +523,8 @@ END_EXTERN_C()
}
#define ZVAL_ZVAL(z, zv, copy, dtor) { \
int is_ref, refcount; \
is_ref = Z_ISREF_P(z); \
refcount = Z_REFCOUNT_P(z); \
zend_uchar is_ref = Z_ISREF_P(z); \
zend_uint refcount = Z_REFCOUNT_P(z); \
*(z) = *(zv); \
if (copy) { \
zval_copy_ctor(z); \

View File

@ -1654,7 +1654,7 @@ ZEND_FUNCTION(get_defined_constants)
zend_constant *val;
int module_number;
zval **modules;
const char **module_names;
char **module_names;
zend_module_entry *module;
int i = 1;
@ -1664,7 +1664,7 @@ ZEND_FUNCTION(get_defined_constants)
module_names[0] = "internal";
zend_hash_internal_pointer_reset_ex(&module_registry, &pos);
while (zend_hash_get_current_data_ex(&module_registry, (void *) &module, &pos) != FAILURE) {
module_names[i++] = module->name;
module_names[i++] = (char*)module->name;
zend_hash_move_forward_ex(&module_registry, &pos);
}
module_names[i] = "user";

View File

@ -422,7 +422,7 @@ int zend_user_serialize(zval *object, unsigned char **buffer, zend_uint *buf_len
zval_ptr_dtor(&retval);
return FAILURE;
case IS_STRING:
*buffer = estrndup(Z_STRVAL_P(retval), Z_STRLEN_P(retval));
*buffer = (unsigned char*)estrndup(Z_STRVAL_P(retval), Z_STRLEN_P(retval));
*buf_len = Z_STRLEN_P(retval);
result = SUCCESS;
break;

View File

@ -4099,7 +4099,7 @@ ZEND_VM_HANDLER(150, ZEND_USER_OPCODE, ANY, ANY)
case ZEND_USER_OPCODE_DISPATCH:
ZEND_VM_DISPATCH(EX(opline)->opcode, EX(opline));
default:
ZEND_VM_DISPATCH(ret & 0xff, EX(opline));
ZEND_VM_DISPATCH((zend_uchar)(ret & 0xff), EX(opline));
}
}

View File

@ -612,7 +612,7 @@ static int ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
case ZEND_USER_OPCODE_DISPATCH:
ZEND_VM_DISPATCH(EX(opline)->opcode, EX(opline));
default:
ZEND_VM_DISPATCH(ret & 0xff, EX(opline));
ZEND_VM_DISPATCH((zend_uchar)(ret & 0xff), EX(opline));
}
}