diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2020-03-26 16:16:44 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2020-03-26 16:16:44 +0200 |
commit | 9348dbda0b0a0471749092632e2675a648ca9e54 (patch) | |
tree | d58d9ecb47c7bb7f36a177488f85f1079c000cfb | |
parent | ee278a1f44a6f12eddbe11f159f17485a616af98 (diff) | |
download | vmod-binlog-9348dbda0b0a0471749092632e2675a648ca9e54.tar.gz vmod-binlog-9348dbda0b0a0471749092632e2675a648ca9e54.tar.bz2 |
Dropped support for varnish < 6.0
-rw-r--r-- | NEWS | 7 | ||||
-rw-r--r-- | README | 2 | ||||
m--------- | acvmod | 0 | ||||
-rw-r--r-- | configure.ac | 4 | ||||
-rw-r--r-- | src/binlog.c | 23 |
5 files changed, 17 insertions, 19 deletions
@@ -1,8 +1,13 @@ -Vmod-binlog NEWS -- history of user-visible changes. 2020-03-10 +Vmod-binlog NEWS -- history of user-visible changes. 2020-03-26 See the end of file for copying conditions. Please send Vmod-binlog bug reports to <gray@gnu.org> +Version 2.5.90 (git) + +* Dropped support for Varnish versions prior to 6.0 + + Version 2.5, 2020-03-10 * Restore backward compatibility with Varnish versions prior to 6.2. @@ -22,7 +22,7 @@ big amounts of information arriving at high rates. The package provides the module itself and the utilities for listing and searching in binary log files. -The module was tested with Varnish versions 4.1 through 6.0.2. +The module was tested with Varnish versions 6.0.2 through 6.3.2. * Installation diff --git a/acvmod b/acvmod -Subproject 5b214e3d72f9e261a37cf31deb41e7f8a61a181 +Subproject b68d558d7aef78eca1417e59ebb0ae38c276e9e diff --git a/configure.ac b/configure.ac index 0c91590..6f28517 100644 --- a/configure.ac +++ b/configure.ac @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with vmod-binlog. If not, see <http://www.gnu.org/licenses/>. AC_PREREQ(2.69) -AC_INIT([vmod-binlog], 2.5, [gray@gnu.org]) +AC_INIT([vmod-binlog], 2.5.90, [gray@gnu.org]) AC_CONFIG_AUX_DIR([build-aux]) AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_SRCDIR(src/binlog.c) @@ -52,7 +52,7 @@ AC_SYS_LARGEFILE AC_HEADER_STDC AC_CHECK_HEADERS([sys/stdlib.h]) -AM_VARNISHAPI([4.1],[6.3.2]) +AM_VARNISHAPI([6.0],[6.3.2]) AC_DEFINE_UNQUOTED([VARNISHAPI_MAJOR],[$VARNISHAPI_MAJOR], [Varnish API major version number]) AC_SUBST(BINLOGSEL_MODDIR,'$(libdir)/$(PACKAGE)') diff --git a/src/binlog.c b/src/binlog.c index 512503d..196c3c1 100644 --- a/src/binlog.c +++ b/src/binlog.c @@ -28,17 +28,10 @@ #include <ctype.h> #include <time.h> #include <string.h> -#if VARNISHAPI_MAJOR > 5 -# include "cache/cache.h" -# include "vcl.h" -# include "vcc_if.h" -#else -# include "vcl.h" -# include "vrt.h" -# include "vcc_if.h" -# include "cache/cache.h" -#endif -#define WSPTR(s) ((s)->ws) + +#include <cache/cache.h> +#include <vcl.h> +#include <vcc_if.h> #ifdef VPFX # define VEVENT(a) VPFX(a) @@ -454,16 +447,16 @@ mkfilename(VRT_CTX, struct binlog_config *conf) if (conf->flags & BLF_ROUNDTS) ts -= ts % conf->interval; - u = WS_Reserve(WSPTR(ctx), 0); - p = WSPTR(ctx)->f; + u = WS_ReserveAll(ctx->ws); + p = ctx->ws->f; n = strftime(p, u, conf->pattern, gmtime(&ts)); if (n == 0) { - WS_Release(WSPTR(ctx), 0); + WS_Release(ctx->ws, 0); return NULL; } q = strdup(p); AN(q); - WS_Release(WSPTR(ctx), 0); + WS_Release(ctx->ws, 0); return q; } |