same thread (the main thread in fact).
Add an assert facility to mark the affected functions, just to make sure
nobody (else) gets an anciety attack over missing locking.
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2428
d4fa192b-c00b-0410-8231-
f00ffab90ce4
/* cache_cli.c [CLI] */
void CLI_Init(void);
+extern pthread_t cli_thread;
+#define ASSERT_CLI() do {assert(phtread_self() == cli_thread);} while (0)
/* cache_expiry.c */
void EXP_Insert(struct object *o);
#include "vsb.h"
#include "heritage.h"
+pthread_t cli_thread;
+
/*--------------------------------------------------------------------*/
static void
cli = &clis;
memset(cli, 0, sizeof *cli);
+ cli_thread = pthread_self();
cli->sb = vsb_new(NULL, NULL, 0, VSB_AUTOEXTEND);
XXXAN(cli->sb);
lbuf = 4096;