pike.git / src / builtin.cmod

version» Context lines:

pike.git/src/builtin.cmod:2899:    struct identifier *function = NULL;       call_c_initializers(o);       size--;       SET_SVAL(res->item[size], PIKE_T_OBJECT, 0, object, o);       bf = OBJ2_BACKTRACE_FRAME(o);    -  if ((bf->prog = f->context->prog)) { +  if (f->type == FRAME_PIKE_FUNCTION && f->context && (bf->prog = f->context->prog)) {    add_ref(bf->prog);    bf->pc = f->pc;    }       SET_SVAL(bf->_fun, PIKE_T_INT, NUMBER_DESTRUCTED, integer, 0);       if (f->current_object && f->current_object->prog) { -  if (f->fun == FUNCTION_BUILTIN) { +  if (f->type == FRAME_BUILTIN) {    /* Unusual case. The frame is from call_c_initializers(), gc()    * or similar. cf [bug 6156]. /grubba    *    * Masquerade as the program.    *    * FIXME: Ought to keep parent-pointers.    */    SET_SVAL(bf->_fun, PIKE_T_PROGRAM, 0,    program, f->current_object->prog);    add_ref(f->current_object->prog);