pike.git / src / mapping.c

version» Context lines:

pike.git/src/mapping.c:404:    to->type=T_INT;    to->subtype=NUMBER_UNDEFINED;    to->u.integer=0;    return;    }    array_index_no_free(to,m->ind,start_pos);   }      #ifdef DEBUG    - void check_mapping(struct mapping *m,int pass) + void check_mapping(struct mapping *m)   { -  if(pass) -  { -  if(checked((void *)m,0) != m->refs) -  fatal("Mapping has wrong number of refs.\n"); -  return; -  } -  +     if(m->refs <=0)    fatal("Mapping has zero refs.\n");       if(m->next && m->next->prev != m)    fatal("Mapping ->next->prev != mapping.\n");       if(m->prev)    {    if(m->prev->next != m)    fatal("Mapping ->prev->next != mapping.\n");    }else{    if(first_mapping != m)    fatal("Mapping ->prev == 0 but first_mapping != mapping.\n");    } -  checked((void *)m->ind,1); -  checked((void *)m->val,1); +    }    - void check_all_mappings(int pass) + void check_all_mappings()   {    struct mapping *m;    for(m=first_mapping;m;m=m->next) -  check_mapping(m,pass); -  -  if(!pass) -  checked((void *)first_mapping,1); +  check_mapping(m);   }   #endif