Changeset 627 for branches/1.3/xcache.c
- Timestamp:
- 2009-07-05T11:24:38+02:00 (4 years ago)
- Location:
- branches/1.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/1.3
- Property svn:mergeinfo changed
/trunk merged: 585,588-592
- Property svn:mergeinfo changed
-
branches/1.3/xcache.c
r626 r627 1594 1594 } 1595 1595 /* }}} */ 1596 static void xc_copy_zend_constant(zend_constant *c) /* {{{ */ 1597 { 1598 c->name = zend_strndup(c->name, c->name_len - 1); 1599 if (!(c->flags & CONST_PERSISTENT)) { 1600 zval_copy_ctor(&c->value); 1601 } 1602 } 1603 /* }}} */ 1596 1604 static void xc_request_init(TSRMLS_D) /* {{{ */ 1597 1605 { … … 1599 1607 1600 1608 if (!XG(internal_table_copied)) { 1609 #ifdef HAVE_XCACHE_CONSTANT 1610 zend_constant tmp_const; 1611 #endif 1601 1612 zend_function tmp_func; 1602 1613 xc_cest_t tmp_cest; 1603 1614 1615 #ifdef HAVE_XCACHE_CONSTANT 1616 zend_hash_destroy(&XG(internal_constant_table)); 1617 #endif 1604 1618 zend_hash_destroy(&XG(internal_function_table)); 1605 1619 zend_hash_destroy(&XG(internal_class_table)); 1606 1620 1621 #ifdef HAVE_XCACHE_CONSTANT 1622 zend_hash_init_ex(&XG(internal_constant_table), 20, NULL, NULL, 1, 0); 1623 #endif 1607 1624 zend_hash_init_ex(&XG(internal_function_table), 100, NULL, NULL, 1, 0); 1608 1625 zend_hash_init_ex(&XG(internal_class_table), 10, NULL, NULL, 1, 0); 1609 1626 1627 #ifdef HAVE_XCACHE_CONSTANT 1628 zend_hash_copy(&XG(internal_constant_table), EG(zend_constants), (copy_ctor_func_t) xc_copy_zend_constant, &tmp_const, sizeof(tmp_const)); 1629 #endif 1610 1630 zend_hash_copy(&XG(internal_function_table), CG(function_table), NULL, &tmp_func, sizeof(tmp_func)); 1611 1631 zend_hash_copy(&XG(internal_class_table), CG(class_table), NULL, &tmp_cest, sizeof(tmp_cest)); … … 1666 1686 memset(xcache_globals, 0, sizeof(zend_xcache_globals)); 1667 1687 1688 #ifdef HAVE_XCACHE_CONSTANT 1689 zend_hash_init_ex(&xcache_globals->internal_constant_table, 1, NULL, NULL, 1, 0); 1690 #endif 1668 1691 zend_hash_init_ex(&xcache_globals->internal_function_table, 1, NULL, NULL, 1, 0); 1669 1692 zend_hash_init_ex(&xcache_globals->internal_class_table, 1, NULL, NULL, 1, 0); … … 1697 1720 1698 1721 if (xcache_globals->internal_table_copied) { 1722 #ifdef HAVE_XCACHE_CONSTANT 1723 zend_hash_destroy(&xcache_globals->internal_constant_table); 1724 #endif 1699 1725 zend_hash_destroy(&xcache_globals->internal_function_table); 1700 1726 zend_hash_destroy(&xcache_globals->internal_class_table);
Note: See TracChangeset
for help on using the changeset viewer.

