New upstream release varnish-6.5.0

Respun silly patch to get rid of compiler warnings on el6
This commit is contained in:
Ingvar Hagelund 2020-09-16 12:08:17 +02:00
parent 0f66bf1df4
commit 6d591be49e
4 changed files with 90 additions and 8 deletions

1
.gitignore vendored
View File

@ -42,3 +42,4 @@ varnish-2.1.3.tar.gz
/pkg-varnish-cache-ec7ad9e.tar.gz
/varnish-6.3.2.tgz
/varnish-6.4.0.tgz
/varnish-6.5.0.tgz

View File

@ -1,2 +1,2 @@
SHA512 (varnish-6.5.0.tgz) = 43f8cd6429a903a353ac4448b6e9aff445b0d52178141a148d3b29b987c0974841820af0da4917731775b46899c12b0327d64d12e3ddbb8fd438e2802ac66a1c
SHA512 (pkg-varnish-cache-ec7ad9e.tar.gz) = 146aacec76b2ca641bb8bc9dda49e82d28740dbcba034e73a8d39387696f10fa3108ab124a078e900865388217352d112f63f6fe9ef7b23e20bc699441aab4f2
SHA512 (varnish-6.4.0.tgz) = cda8f9e1d301a2b79db14685a23e25e36225f37065a1b7f37c5ae12fbb0483be51be9ffcc8ba72c1f65f5a022d1e408825694daed6780e206b9ba91feb2a07a1

View File

@ -0,0 +1,78 @@
diff -Naur ../varnish-6.5.0.orig/bin/varnishd/http1/cache_http1_deliver.c ./bin/varnishd/http1/cache_http1_deliver.c
--- ../varnish-6.5.0.orig/bin/varnishd/http1/cache_http1_deliver.c 2020-09-15 17:06:03.000000000 +0200
+++ ./bin/varnishd/http1/cache_http1_deliver.c 2020-09-16 11:45:28.663086943 +0200
@@ -76,7 +76,7 @@
VSLb(req->vsl, SLT_RespReason, "Internal Server Error");
req->wrk->stats->client_resp_500++;
- (void)write(req->sp->fd, r_500, sizeof r_500 - 1);
+ if (write(req->sp->fd, r_500, sizeof r_500 - 1)) 0;
req->doclose = SC_TX_EOF;
}
diff -Naur ../varnish-6.5.0.orig/bin/varnishd/mgt/mgt_main.c ./bin/varnishd/mgt/mgt_main.c
--- ../varnish-6.5.0.orig/bin/varnishd/mgt/mgt_main.c 2020-09-15 17:06:03.000000000 +0200
+++ ./bin/varnishd/mgt/mgt_main.c 2020-09-16 11:46:21.323667133 +0200
@@ -252,7 +252,7 @@
return;
VJ_rmdir("vmod_cache");
VJ_unlink("_.pid");
- (void)chdir("/");
+ if (chdir("/")) 0;
VJ_rmdir(workdir);
}
diff -Naur ../varnish-6.5.0.orig/bin/varnishd/mgt/mgt_param.c ./bin/varnishd/mgt/mgt_param.c
--- ../varnish-6.5.0.orig/bin/varnishd/mgt/mgt_param.c 2020-09-15 17:06:03.000000000 +0200
+++ ./bin/varnishd/mgt/mgt_param.c 2020-09-16 11:45:28.771086082 +0200
@@ -829,11 +829,11 @@
t2 = strchr(t1 + 1, '\t');
AN(t2);
printf("\n\t*");
- (void)fwrite(t1 + 1, (t2 - 1) - t1, 1, stdout);
+ if (fwrite(t1 + 1, (t2 - 1) - t1, 1, stdout)) 1;
printf("*\n\t\t");
p = t2 + 1;
}
- (void)fwrite(p, q - p, 1, stdout);
+ if(fwrite(p, q - p, 1, stdout)) 1;
p = q;
if (*p == '\n') {
printf("\n");
diff -Naur ../varnish-6.5.0.orig/bin/varnishtest/vtc_main.c ./bin/varnishtest/vtc_main.c
--- ../varnish-6.5.0.orig/bin/varnishtest/vtc_main.c 2020-09-15 17:06:03.000000000 +0200
+++ ./bin/varnishtest/vtc_main.c 2020-09-16 11:45:28.771086082 +0200
@@ -233,7 +233,7 @@
assert(cleaner_pid >= 0);
if (cleaner_pid == 0) {
closefd(&p[1]);
- (void)nice(1); /* Not important */
+ if (nice(1)) 1;
setbuf(stdin, NULL);
AZ(dup2(p[0], STDIN_FILENO));
while (fgets(buf, sizeof buf, stdin)) {
diff -Naur ../varnish-6.5.0.orig/lib/libvarnishapi/vsm.c ./lib/libvarnishapi/vsm.c
--- ../varnish-6.5.0.orig/lib/libvarnishapi/vsm.c 2020-09-15 17:06:03.000000000 +0200
+++ ./lib/libvarnishapi/vsm.c 2020-09-16 11:45:28.772086074 +0200
@@ -764,18 +764,18 @@
VSM_ResetError(vd);
if (u & VSM_MGT_RUNNING) {
if (progress >= 0 && n > 4)
- (void)write(progress, "\n", 1);
+ if (!write(progress, "\n", 1)) return (vsm_diag(vd, "Unable to write progress"));
vd->attached = 1;
return (0);
}
if (t0 < VTIM_mono()) {
if (progress >= 0 && n > 4)
- (void)write(progress, "\n", 1);
+ if (!write(progress, "\n", 1)) return (vsm_diag(vd, "Unable to write progress"));
return (vsm_diag(vd,
"Could not get hold of varnishd, is it running?"));
}
if (progress >= 0 && !(++n % 4))
- (void)write(progress, ".", 1);
+ if (!write(progress, ".", 1)) return (vsm_diag(vd, "Unable to write progress"));
VTIM_sleep(.25);
}
return (vsm_diag(vd, "Attach interrupted"));

View File

@ -1,5 +1,4 @@
%global _hardened_build 1
%global _hardened_build 0
# https://github.com/varnishcache/varnish-cache/issues/2269
%global debug_package %{nil}
@ -23,11 +22,11 @@
Summary: High-performance HTTP accelerator
Name: varnish
Version: 6.4.0
Release: 4%{?dist}
Version: 6.5.0
Release: 1%{?dist}
License: BSD
URL: https://www.varnish-cache.org/
Source0: http://varnish-cache.org/_downloads/%{name}-%{version}%{?vd_rc}.tgz
Source0: http://varnish-cache.org/_downloads/%{name}-%{version}.tgz
Source1: https://github.com/varnishcache/pkg-varnish-cache/archive/%{commit1}.tar.gz#/pkg-varnish-cache-%{shortcommit1}.tar.gz
# Patches:
@ -57,7 +56,7 @@ Patch4: varnish-4.0.3_fix_varnish4_selinux.el6.patch
# Patch 016: Fix some warnings that prohibited clean -Werror compilation
# on el6. Will not be fixed upstream. Patch grows more stupid
# for each iteration :-(
Patch16: varnish-6.4.0_el6_fix_warning_from_old_gcc.patch
Patch16: varnish-6.5.0_el6_fix_warning_from_old_gcc.patch
# Patch 017: Fix stack size on ppc64 in test c_00057, upstream commit 88948d9
#Patch17: varnish-6.2.0_fix_ppc64_for_test_c00057.patch
@ -176,7 +175,7 @@ Minimal selinux policy for running varnish4
%endif
%prep
%setup -q -n varnish-%{version}%{?vd_rc}
%setup -q
tar xzf %SOURCE1
ln -s pkg-varnish-cache-%{commit1}/redhat redhat
ln -s pkg-varnish-cache-%{commit1}/debian debian
@ -433,6 +432,10 @@ fi
%changelog
* Wed Sep 16 2020 Ingvar Hagelund <ingvar@redpill-linpro.com> 6.5.0-1
- New upstream release varnish-6.5.0
- Respun silly patch to get rid of compiler warnings on el6
* Tue Aug 04 2020 Ingvar Hagelund <ingvar@redpill-linpro.com> 6.4.0-4
- Added -Wno-error=free-nonheap-object to CFLAGS to build on s390x