diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2016-01-20 14:40:13 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2016-01-20 14:40:13 +0200 |
commit | 6f72ce19982bd6f7eb9cfe7c2ebcbc221063401d (patch) | |
tree | 522208d44816d8a8bdd9298d1fe7284dbf9267c4 /src/tbf.c | |
parent | 741817ac5372c374b52b710dd8a4b0cc463ade99 (diff) | |
download | vmod-tbf-varnish-4.1.tar.gz vmod-tbf-varnish-4.1.tar.bz2 |
Rewrite for varnishapi 4.1varnish-4.1
* NEWS: Update.
* configure.ac: Raise version number to 2.0.90
* src/tbf.c (tbf_init): Replaced with tbf_event
* src/vmod_tbf.vcc: Likewise.
* src/tbf.h: Include errno.h and vcl.h.
Diffstat (limited to 'src/tbf.c')
-rw-r--r-- | src/tbf.c | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -335,10 +335,13 @@ tbf_open_safe(const char *params) } int -tbf_init(struct vmod_priv *priv, const struct VCL_conf *vclconf) +tbf_event(VRT_CTX, struct vmod_priv *priv, enum vcl_event_e e) { - VTAILQ_INIT(&keylock_head); - VTAILQ_INIT(&keylock_avail); + if (e == VCL_EVENT_LOAD) { + VTAILQ_INIT(&keylock_head); + VTAILQ_INIT(&keylock_avail); + } + return 0; } void |