Moved dcb_hashtable_stats from hastable.c to dcb.c to break dependency between hashtable and the rest of the maxscale. Added check fields to hashtable structure.
This commit is contained in:
@ -113,7 +113,8 @@ typedef enum skygw_chk_t {
|
||||
CHK_NUM_FNAMES,
|
||||
CHK_NUM_LOGMANAGER,
|
||||
CHK_NUM_FILE,
|
||||
CHK_NUM_BLOCKBUF
|
||||
CHK_NUM_BLOCKBUF,
|
||||
CHK_NUM_HASHTABLE
|
||||
} skygw_chk_t;
|
||||
|
||||
# define STRBOOL(b) ((b) ? "TRUE" : "FALSE")
|
||||
@ -319,4 +320,10 @@ typedef enum skygw_chk_t {
|
||||
"Block buf under- or overflow"); \
|
||||
}
|
||||
|
||||
#define CHK_HASHTABLE(t) { \
|
||||
ss_info_dassert(t->ht_chk_top == CHK_NUM_HASHTABLE && \
|
||||
t->ht_chk_tail == CHK_NUM_HASHTABLE, \
|
||||
"Hashtable under- or overflow"); \
|
||||
}
|
||||
|
||||
#endif /* SKYGW_DEBUG_H */
|
||||
|
Reference in New Issue
Block a user