Added check routine for gw_buffer. Only effective in debug build.

This commit is contained in:
vraatikka
2013-09-17 15:10:16 +03:00
parent 5fba84a4ee
commit 4cf5b3293f
2 changed files with 15 additions and 8 deletions

View File

@ -16,7 +16,7 @@
* Copyright SkySQL Ab 2013
*/
#include <stdio.h>
#include <assert.h>
#define __USE_UNIX98 1
@ -360,6 +360,11 @@ typedef enum skygw_chk_t {
"Session under- or overflow"); \
}
#define CHK_GWBUF(b) { \
ss_info_dassert(((b)->start <= (b)->end), \
"gwbuf start has passed the endpoint"); \
}
#if defined(SS_DEBUG)
bool conn_open[1024];
#endif