pike.git / src / stralloc.c

version» Context lines:

pike.git/src/stralloc.c:322: Inside #if defined(DEBUG)
   struct pike_string *s2;    for(s2=s;s2;s2=s2->next)    if(s2 == s)    fatal("Shared string table is cyclic.\n");    h=0;    }    }    }   }    + int safe_debug_findstring(struct pike_string *foo) + { +  unsigned INT32 e; +  if(!base_table) return 0; +  for(e=0;e<htable_size;e++) +  { +  struct pike_string *p; +  for(p=base_table[e];p;p=p->next) +  if(p==foo) return 1; +  } +  return 0; + } +    struct pike_string *debug_findstring(const struct pike_string *foo)   {    struct pike_string *tmp;    tmp=propagate_shared_string(foo, foo->hval % htable_size);      #if 0    if(!tmp)    {    unsigned INT32 e;    struct pike_string *tmp2;