pike.git / src / stralloc.c

version» Context lines:

pike.git/src/stralloc.c:19:      #include <errno.h>   #include <float.h>   #include <ctype.h>   #include <math.h>      #ifndef HUGE   #define HUGE HUGE_VAL   #endif /*!HUGE*/    - RCSID("$Id: stralloc.c,v 1.124 2001/03/30 16:45:42 grubba Exp $"); + RCSID("$Id: stralloc.c,v 1.125 2001/04/13 13:35:30 mast Exp $");      #if PIKE_RUN_UNLOCKED   /* Make this bigger when we get lightweight threads */   #define BUCKET_LOCKS 2048   static PIKE_MUTEX_T *bucket_locks;      #define BUCKETLOCK(HVAL) \    (bucket_locks + ((hval__ % htable_size) & (BUCKET_LOCKS-1)))      #define LOCK_BUCKET(HVAL) do { \
pike.git/src/stralloc.c:880:   /*** Free strings ***/      PMOD_EXPORT void unlink_pike_string(struct pike_string *s)   {    size_t h;    LOCK_BUCKET(s->hval);    h= s->hval % htable_size;    propagate_shared_string(s,h);   #ifdef PIKE_DEBUG    if (base_table[h] != s) { -  fatal("propagate_shared_string() failed!\n"); +  fatal("propagate_shared_string() failed. Probably got bogus pike_string.\n");    }   #endif /* PIKE_DEBUG */    base_table[h]=s->next;   #ifdef PIKE_DEBUG    s->next=(struct pike_string *)(ptrdiff_t)-1;   #endif    num_strings--;    UNLOCK_BUCKET(s->hval);   }