Changeset 634 for branches/1.3/utils.c
- Timestamp:
- 2009-07-05T11:47:17+02:00 (4 years ago)
- File:
-
- 1 edited
-
branches/1.3/utils.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/1.3/utils.c
r627 r634 528 528 #define OG(x) (sandbox->orig_##x) 529 529 /* }}} */ 530 <<<<<<< .working531 =======532 #ifdef E_STRICT533 static void xc_sandbox_error_cb(int type, const char *error_filename, const uint error_lineno, const char *format, va_list args) /* {{{ */534 {535 xc_compilererror_t *compilererror;536 xc_sandbox_t *sandbox;537 TSRMLS_FETCH();538 539 sandbox = (xc_sandbox_t *) XG(sandbox);540 assert(sandbox != NULL);541 if (type != E_STRICT) {542 /* give up, and user handler is not supported in this case */543 zend_uint i;544 zend_uint orig_lineno = CG(zend_lineno);545 zend_error_cb = sandbox->orig_zend_error_cb;546 547 for (i = 0; i < sandbox->compilererror_cnt; i ++) {548 compilererror = &sandbox->compilererrors[i];549 CG(zend_lineno) = compilererror->lineno;550 zend_error(E_STRICT, "%s", compilererror->error);551 }552 CG(zend_lineno) = orig_lineno;553 sandbox->compilererror_cnt = 0;554 555 sandbox->orig_zend_error_cb(type, error_filename, error_lineno, format, args);556 return;557 }558 559 if (sandbox->compilererror_cnt <= sandbox->compilererror_size) {560 if (sandbox->compilererror_size) {561 sandbox->compilererror_size += 16;562 sandbox->compilererrors = erealloc(sandbox->compilererrors, sandbox->compilererror_size * sizeof(sandbox->compilererrors));563 }564 else {565 sandbox->compilererror_size = 16;566 sandbox->compilererrors = emalloc(sandbox->compilererror_size * sizeof(sandbox->compilererrors));567 }568 }569 compilererror = &sandbox->compilererrors[sandbox->compilererror_cnt++];570 compilererror->lineno = error_lineno;571 compilererror->error_len = vspprintf(&compilererror->error, 0, format, args);572 }573 /* }}} */574 #endif575 >>>>>>> .merge-right.r559576 530 #ifdef ZEND_ENGINE_2_1 577 531 static zend_bool xc_auto_global_callback(char *name, uint name_len TSRMLS_DC) /* {{{ */
Note: See TracChangeset
for help on using the changeset viewer.

