a2a57a6247e93612140baa899ddb3c462af8f12e braney Wed Jan 15 23:37:27 2020 -0800 mark hashes that are coming in from trackDb cache so they don't get freed diff --git src/inc/hash.h src/inc/hash.h index 22dc124..361bb43 100644 --- src/inc/hash.h +++ src/inc/hash.h @@ -62,31 +62,31 @@ bits32 hashVal; }; struct hash { struct hash *next; /* Next in list. */ bits32 mask; /* Mask hashCrc with this to get it to fit table. */ struct hashEl **table; /* Hash buckets. */ int powerOfTwoSize; /* Size of table as a power of two. */ int size; /* Size of table. */ struct lm *lm; /* Local memory pool. */ int elCount; /* Count of elements. */ boolean autoExpand; /* Automatically expand hash */ float expansionFactor; /* Expand when elCount > size*expansionFactor */ int numResizes; /* number of times resize was called */ - boolean ownLm; /* TRUE if lm was allocated by newHashExt */ + boolean ownLm; /* TRUE if lm was allocated by newHashExt OR read in from trackDbCache */ }; #define defaultExpansionFactor 1.0 #define hashMaxSize 30 struct hashCookie /* used by hashFirst/hashNext in tracking location in traversing hash */ { struct hash *hash; /* hash we are associated with */ int idx; /* current index in hash */ struct hashEl *nextEl; /* current element in hash */ }; bits32 hashString(char *string);