Re: Crash during compilation

From: Date: Mon, 04 Dec 2000 23:09:00 +0000
Subject: Re: Crash during compilation
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-40053@lists.php.net to get a copy of this message
What about the rest of the compiler_globals structure - does it appear to be overwritten? Zeev At 22:22 4/12/2000, David Hedbor wrote:
Using the latest CVS version of PHP4 I get a crash during compilation. Basically, the error seems to be that compiler_globals->function_table is incorrect (points to 0xe). However I have no clue where to start looking. Some information about the environment: PHP4 CVS from about 10 minutes ago, Caudium SAPI configured like this: --with-caudium --enable-debug --enable-maintainer-mode --with-gd gcc version 2.95.3 19991030 glibc-2.1.3-5mdk Caudium SAPI also implies ZTS. This problem is new (didn't exist a just a week or so ago). -- David P.S. On an unrelated note, when I compile w/o --with-gd I get unresolved references to gd functions (just noticed since I had always used --with-gd before).(gdb) bt #0 _zend_is_inconsistent (ht=0xe,
    file=0x40673264 "../../../Zend/zend_hash.c", line=850)
    at ../../../Zend/zend_hash.c:88
#1 0x405be5c1 in zend_hash_find (ht=0xe, arKey=0x86bf3c4 "str_replace",
    nKeyLength=12, pData=0xbfffcec8) at ../../../Zend/zend_hash.c:850
#2 0x405a1df0 in zend_do_begin_function_call (function_name=0xbfffd09c,
    compiler_globals=0x85ea418) at ../../../Zend/zend_compile.c:812
#3 0x4059def7 in zendparse (compiler_globals=0x85ea418)
    at ../../../Zend/zend_language_parser.y:488
#4 0x405c4356 in compile_file () from /usr/local/caudium/server/lib/7.1.11/PHP4.so #5 0x405b9dbb in zend_execute_scripts (type=8, compiler_globals=0x85ea418,
    executor_globals=0x8534e68, file_count=3) at ../../../Zend/zend.c:726
#6 0x405cf42c in php_execute_script (primary_file=0xbfffef98,
    compiler_globals=0x85ea418, executor_globals=0x8534e68,
    core_globals=0x8481e68) at /home/neotron/src/php4/main/main.c:1221
#7 0x405ccbd8 in php_caudium_module_main (ureq=0x8493e70)
    at /home/neotron/src/php4/sapi/caudium/caudium.c:679
#8 0x405cd0f6 in f_php_caudium_request_handler (args=4)
    at /home/neotron/src/php4/sapi/caudium/caudium.c:755
[ backtrace in pike source snipped ] (gdb) up #2 0x405a1df0 in zend_do_begin_function_call (function_name=0xbfffd09c,
    compiler_globals=0x85ea418) at ../../../Zend/zend_compile.c:812
812             if (zend_hash_find(CG(function_table), function_name->u.constant.value.str.val,function_name->u.constant.value.str..len+1, (void **) &function)==FAILURE) {
(gdb) p compiler_globals $14 = (zend_compiler_globals *) 0x85ea418 (gdb) p *compiler_globals $15 = {bp_stack = {top = 1, max = 64, elements = 0x8631c2c}, switch_cond_stack = {top = 0, max = 64, elements = 0x8626adc}, foreach_copy_stack = {top = 0, max = 64, elements = 0x86a4dac}, object_stack = {top = 0, max = 64, elements = 0x86a4ebc}, declare_stack = {
    top = 0, max = 64, elements = 0x84fe0dc}, class_entry = {type = 101 'e',
    name = 0x608 <Address 0x608 out of bounds>, name_length = 48,
    parent = 0x0, refcount = 0x151, constants_updated = 8 '\b',
    function_table = {nTableSize = 1075310344, nHashSizeIndex = 4294967295,
      nNumOfElements = 1634558307, nNextFreeElement = 1886609267,
      pHashFunction = 0x73696e61, pInternalPointer = 0x69702e68,
      pListHead = 0x3a00656b, pListTail = 0x8, arBuckets = 0x129,
      pDestructor = 0x4017f028 <__morecore+328>, persistent = 40 '(',
      nApplyCount = 240 'ð', bApplyProtection = 23 '\027'},
    default_properties = {nTableSize = 138836520, nHashSizeIndex = 14,
      nNumOfElements = 14, nNextFreeElement = 64, pHashFunction = 0x6,
      pInternalPointer = 0x83e97d4, pListHead = 0x6, pListTail = 0x850eb00,
      arBuckets = 0x6, pDestructor = 0x85d745c, persistent = 6 '\006',
      nApplyCount = 0 '\000', bApplyProtection = 0 '\000'},
    builtin_functions = 0x85d72f4, handle_function_call = 0x6,
    handle_property_get = 0x85d7de4, handle_property_set = 0x6},
active_class_entry = 0x0, list_llist = {head = 0x0, tail = 0x0, size = 56,
    dtor = 0, persistent = 0 '\000', traverse_ptr = 0x85ea3a0},
dimension_llist = {head = 0x0, tail = 0x0, size = 4, dtor = 0,
    persistent = 0 '\000', traverse_ptr = 0x85ea430}, function_call_stack = {
    top = 0, max = 64, elements = 0x863242c},
  compiled_filename = 0x86bf1cc "/home/neotron/html/bug.php", zend_lineno = 2,
comment_start_line = 0, heredoc = 0x0, heredoc_len = 0, active_op_array = 0x86c37c4, function_table = 0xe, class_table = 0xe, filenames_table = {nTableSize = 5, nHashSizeIndex = 0, nNumOfElements = 1,
    nNextFreeElement = 0, pHashFunction = 0x405bcaf8 <hashpjw>,
    pInternalPointer = 0x86bf1fc, pListHead = 0x86bf1fc,
    pListTail = 0x86bf1fc, arBuckets = 0x84821a4,
    pDestructor = 0x405a0270 <free_filename>, persistent = 0 '\000',
    nApplyCount = 0 '\000', bApplyProtection = 1 '\001'},
in_compilation = 1 '\001', short_tags = 0 '\000', asp_tags = 0 '\000', allow_call_time_pass_reference = 0 '\000', declarables = {ticks = {value = {
        lval = 0, dval = 1.2731974745791634e-313, str = {val = 0x0, len = 6},
        ht = 0x0, obj = {ce = 0x0, properties = 0x6}}, type = 1 '\001',
      is_ref = 1 '\001', refcount = 256}}, extended_info = 6 '\006',
handle_op_arrays = 1 '\001', unclean_shutdown = 0 '\000', ini_parser_unbuffered_errors = 0 '\000', open_files = {head = 0x86c3ad4,
    tail = 0x86c3ad4, size = 20, dtor = 0x405c3bb8 <zend_file_handle_dtor>,
    persistent = 0 '\000', traverse_ptr = 0x6}, ZFL = 0x86c3af8,
ini_parser = 0x6} (gdb) p compiler_globals->function_table $16 = (HashTable *) 0xe -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net For additional commands, e-mail: php-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net
-- Zeev Suraski <zeev@zend.com> CTO, Zend Technologies Ltd. http://www.zend.com/

« previous php.dev (#40053) next »