Changeset 856 in svn


Ignore:
Timestamp:
2012-03-28T11:30:46+02:00 (3 years ago)
Author:
Xuefer
Message:

store entry_var_t

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/processor/head.m4

    r854 r856  
    416416        zend_hash_destroy(&processor.strings);
    417417    }
    418     src->ifelse(`$1', `xc_entry_php_t', entry.)size = processor.size;
     418    src->ifelse(
     419        `$1', `xc_entry_data_php_t', `',
     420        `', `', entry.)size = processor.size;
    419421    ifelse(
    420422        `$1', `xc_entry_var_t', `src->have_references = processor.have_references;',
     
    467469/* }}} */
    468470')
    469 DEFINE_STORE_API(`xc_entry_t')
     471DEFINE_STORE_API(`xc_entry_var_t')
    470472DEFINE_STORE_API(`xc_entry_php_t')
    471473DEFINE_STORE_API(`xc_entry_data_php_t')
     
    502504}
    503505/* }}} */
    504 /* export: xc_entry_t *xc_processor_restore_xc_entry_t(xc_entry_t *dst, const xc_entry_t *src TSRMLS_DC); :export {{{ */
    505 xc_entry_t *xc_processor_restore_xc_entry_t(xc_entry_t *dst, const xc_entry_t *src TSRMLS_DC) {
     506/* export: xc_entry_var_t *xc_processor_restore_xc_entry_var_t(xc_entry_var_t *dst, const xc_entry_var_t *src TSRMLS_DC); :export {{{ */
     507xc_entry_var_t *xc_processor_restore_xc_entry_var_t(xc_entry_var_t *dst, const xc_entry_var_t *src TSRMLS_DC) {
    506508    xc_processor_t processor;
    507509
    508510    memset(&processor, 0, sizeof(processor));
    509     xc_restore_xc_entry_t(&processor, dst, src TSRMLS_CC);
     511    xc_restore_xc_entry_var_t(&processor, dst, src TSRMLS_CC);
    510512
    511513    return dst;
     
    535537#ifdef HAVE_XCACHE_DPRINT
    536538void xc_dprint(xc_entry_php_t *src, int indent TSRMLS_DC) {
    537     IFDPRINT(`INDENT()`'fprintf(stderr, "xc_entry_t:src");')
    538     xc_dprint_xc_entry_t(src, indent TSRMLS_CC);
    539 }
    540 #endif
    541 /* }}} */
     539    IFDPRINT(`INDENT()`'fprintf(stderr, "xc_entry_php_t:src");')
     540    xc_dprint_xc_entry_php_t(src, indent TSRMLS_CC);
     541}
     542#endif
     543/* }}} */
  • trunk/processor/main.m4

    r851 r856  
    252252EXPORT(`xc_classinfo_t')
    253253EXPORT(`xc_funcinfo_t')
    254 EXPORT(`xc_entry_t')
     254EXPORT(`xc_entry_var_t')
    255255EXPORT(`xc_entry_php_t')
    256256EXPORT(`xc_entry_data_php_t')
  • trunk/processor/processor.m4

    r854 r856  
    1010#endif
    1111DECL_STRUCT_P_FUNC(`zend_function')
    12 DECL_STRUCT_P_FUNC(`xc_entry_t')
     12DECL_STRUCT_P_FUNC(`xc_entry_var_t')
     13DECL_STRUCT_P_FUNC(`xc_entry_php_t')
    1314#ifdef ZEND_ENGINE_2
    1415DECL_STRUCT_P_FUNC(`zend_property_info')
  • trunk/xcache.c

    r854 r856  
    267267    stored_xce = type == XC_TYPE_PHP
    268268        ? (xc_entry_t *) xc_processor_store_xc_entry_php_t(cache, (xc_entry_php_t *) xce TSRMLS_CC)
    269         : xc_processor_store_xc_entry_t(cache, xce TSRMLS_CC);
     269        : (xc_entry_t *) xc_processor_store_xc_entry_var_t(cache, (xc_entry_var_t *) xce TSRMLS_CC);
    270270    if (stored_xce) {
    271271        xc_entry_add_dmz(cache, entryslotid, stored_xce);
     
    281281{
    282282    return (xc_entry_php_t *) xc_entry_store_dmz(XC_TYPE_PHP, cache, entryslotid, (xc_entry_t *) xce TSRMLS_CC);
     283}
     284/* }}} */
     285static xc_entry_var_t *xc_entry_var_store_dmz(xc_cache_t *cache, xc_hash_value_t entryslotid, xc_entry_var_t *xce TSRMLS_DC) /* {{{ */
     286{
     287    return (xc_entry_var_t *) xc_entry_store_dmz(XC_TYPE_VAR, cache, entryslotid, (xc_entry_t *) xce TSRMLS_CC);
    283288}
    284289/* }}} */
     
    27542759        }
    27552760        xce.value = value;
    2756         RETVAL_BOOL(xc_entry_store_dmz(XC_TYPE_VAR, cache, entry_hash.entryslotid, (xc_entry_t *) &xce TSRMLS_CC) != NULL ? 1 : 0);
     2761        RETVAL_BOOL(xc_entry_var_store_dmz(cache, entry_hash.entryslotid, &xce TSRMLS_CC) != NULL ? 1 : 0);
    27572762    } LEAVE_LOCK(cache);
    27582763}
     
    29442949            xc_entry_remove_dmz(XC_TYPE_VAR, cache, entry_hash.cacheslotid, (xc_entry_t *) stored_xce TSRMLS_CC);
    29452950        }
    2946         xc_entry_store_dmz(XC_TYPE_VAR, cache, entry_hash.cacheslotid, (xc_entry_t *) &xce TSRMLS_CC);
     2951        xc_entry_var_store_dmz(cache, entry_hash.cacheslotid, &xce TSRMLS_CC);
    29472952
    29482953    } LEAVE_LOCK(cache);
Note: See TracChangeset for help on using the changeset viewer.