|
|
|
@ -424,7 +424,7 @@ static int xc_do_early_binding(zend_op_array *op_array, HashTable *class_table,
|
|
|
|
|
/* }}} */
|
|
|
|
|
|
|
|
|
|
#ifdef HAVE_XCACHE_CONSTANT
|
|
|
|
|
void xc_install_constant(char *filename, zend_constant *constant, zend_uchar type, zstr key, uint len TSRMLS_DC) /* {{{ */
|
|
|
|
|
void xc_install_constant(char *filename, zend_constant *constant, zend_uchar type, zstr key, uint len, ulong h TSRMLS_DC) /* {{{ */
|
|
|
|
|
{
|
|
|
|
|
if (zend_u_hash_add(EG(zend_constants), type, key, len,
|
|
|
|
|
constant, sizeof(zend_constant),
|
|
|
|
@ -444,7 +444,7 @@ void xc_install_constant(char *filename, zend_constant *constant, zend_uchar typ
|
|
|
|
|
}
|
|
|
|
|
/* }}} */
|
|
|
|
|
#endif
|
|
|
|
|
void xc_install_function(char *filename, zend_function *func, zend_uchar type, zstr key, uint len TSRMLS_DC) /* {{{ */
|
|
|
|
|
void xc_install_function(char *filename, zend_function *func, zend_uchar type, zstr key, uint len, ulong h TSRMLS_DC) /* {{{ */
|
|
|
|
|
{
|
|
|
|
|
zend_bool istmpkey;
|
|
|
|
|
|
|
|
|
@ -474,7 +474,7 @@ void xc_install_function(char *filename, zend_function *func, zend_uchar type, z
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
/* }}} */
|
|
|
|
|
ZESW(xc_cest_t *, void) xc_install_class(char *filename, xc_cest_t *cest, int oplineno, zend_uchar type, zstr key, uint len TSRMLS_DC) /* {{{ */
|
|
|
|
|
ZESW(xc_cest_t *, void) xc_install_class(char *filename, xc_cest_t *cest, int oplineno, zend_uchar type, zstr key, uint len, ulong h TSRMLS_DC) /* {{{ */
|
|
|
|
|
{
|
|
|
|
|
zend_bool istmpkey;
|
|
|
|
|
zend_class_entry *cep = CestToCePtr(*cest);
|
|
|
|
@ -486,7 +486,7 @@ ZESW(xc_cest_t *, void) xc_install_class(char *filename, xc_cest_t *cest, int op
|
|
|
|
|
istmpkey = ZSTR_S(key)[0] == 0;
|
|
|
|
|
#endif
|
|
|
|
|
if (istmpkey) {
|
|
|
|
|
zend_u_hash_update(CG(class_table), type, key, len,
|
|
|
|
|
zend_u_hash_quick_update(CG(class_table), type, key, len, h,
|
|
|
|
|
cest, sizeof(xc_cest_t),
|
|
|
|
|
ZESW(&stored_ce_ptr, NULL)
|
|
|
|
|
);
|
|
|
|
@ -494,7 +494,7 @@ ZESW(xc_cest_t *, void) xc_install_class(char *filename, xc_cest_t *cest, int op
|
|
|
|
|
xc_do_early_binding(CG(active_op_array), CG(class_table), oplineno TSRMLS_CC);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else if (zend_u_hash_add(CG(class_table), type, key, len,
|
|
|
|
|
else if (zend_u_hash_quick_add(CG(class_table), type, key, len, h,
|
|
|
|
|
cest, sizeof(xc_cest_t),
|
|
|
|
|
ZESW(&stored_ce_ptr, NULL)
|
|
|
|
|
) == FAILURE) {
|
|
|
|
@ -684,7 +684,7 @@ static void xc_sandbox_install(xc_sandbox_t *sandbox, xc_install_action_t instal
|
|
|
|
|
while (b != NULL) {
|
|
|
|
|
zend_constant *c = (zend_constant*) b->pData;
|
|
|
|
|
xc_install_constant(sandbox->filename, c,
|
|
|
|
|
BUCKET_KEY_TYPE(b), ZSTR(BUCKET_KEY_S(b)), b->nKeyLength TSRMLS_CC);
|
|
|
|
|
BUCKET_KEY_TYPE(b), ZSTR(BUCKET_KEY_S(b)), b->nKeyLength, b->h TSRMLS_CC);
|
|
|
|
|
b = b->pListNext;
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
@ -694,7 +694,7 @@ static void xc_sandbox_install(xc_sandbox_t *sandbox, xc_install_action_t instal
|
|
|
|
|
while (b != NULL) {
|
|
|
|
|
zend_function *func = (zend_function*) b->pData;
|
|
|
|
|
xc_install_function(sandbox->filename, func,
|
|
|
|
|
BUCKET_KEY_TYPE(b), ZSTR(BUCKET_KEY_S(b)), b->nKeyLength TSRMLS_CC);
|
|
|
|
|
BUCKET_KEY_TYPE(b), ZSTR(BUCKET_KEY_S(b)), b->nKeyLength, b->h TSRMLS_CC);
|
|
|
|
|
b = b->pListNext;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -702,7 +702,7 @@ static void xc_sandbox_install(xc_sandbox_t *sandbox, xc_install_action_t instal
|
|
|
|
|
/* install class */
|
|
|
|
|
while (b != NULL) {
|
|
|
|
|
xc_install_class(sandbox->filename, (xc_cest_t*) b->pData, -1,
|
|
|
|
|
BUCKET_KEY_TYPE(b), ZSTR(BUCKET_KEY_S(b)), b->nKeyLength TSRMLS_CC);
|
|
|
|
|
BUCKET_KEY_TYPE(b), ZSTR(BUCKET_KEY_S(b)), b->nKeyLength, b->h TSRMLS_CC);
|
|
|
|
|
b = b->pListNext;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|