diff --git a/fix-build-error-with-gcc-10.patch b/fix-build-error-with-gcc-10.patch new file mode 100644 index 0000000..21316d3 --- /dev/null +++ b/fix-build-error-with-gcc-10.patch @@ -0,0 +1,28 @@ +From 486660deabfa33375df2c8f053d84d6128a1235f Mon Sep 17 00:00:00 2001 +From: Francesco Chemolli +Date: Sat, 21 Mar 2020 22:18:43 +0000 +Subject: [PATCH] FtpGateway.cc: fix build on gcc-10 [-Werror=class-memaccess] + (#573) + +Since a1c06c7, tokens initialization is done by FtpLineToken +constructor, and g++-10 complains about memsetting a nontrivial object: + + clearing an object of non-trivial type [-Werror=class-memaccess] +--- + src/clients/FtpGateway.cc | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/src/clients/FtpGateway.cc b/src/clients/FtpGateway.cc +index 79de14d7889..c0350116727 100644 +--- a/src/clients/FtpGateway.cc ++++ b/src/clients/FtpGateway.cc +@@ -563,8 +563,6 @@ ftpListParseParts(const char *buf, struct Ftp::GatewayFlags flags) + + n_tokens = 0; + +- memset(tokens, 0, sizeof(tokens)); +- + xbuf = xstrdup(buf); + + if (flags.tried_nlst) { + diff --git a/squid.spec b/squid.spec index 4637e12..fdffbaf 100644 --- a/squid.spec +++ b/squid.spec @@ -2,7 +2,7 @@ Name: squid Version: 4.9 -Release: 9 +Release: 10 Summary: The Squid proxy caching server Epoch: 7 License: GPLv2+ and (LGPLv2+ and MIT and BSD and Public Domain) @@ -40,6 +40,7 @@ Patch19:backport-0002-CVE-2021-28652.patch Patch20:backport-CVE-2021-28662.patch Patch21:backport-CVE-2021-31806-CVE-2021-31808.patch Patch22:backport-CVE-2021-33620.patch +Patch23:fix-build-error-with-gcc-10.patch Buildroot: %{_tmppath}/squid-4.9-1-root-%(%{__id_u} -n) Requires: bash >= 2.0 @@ -224,6 +225,12 @@ fi chgrp squid /var/cache/samba/winbindd_privileged >/dev/null 2>&1 || : %changelog +* Fri Jul 30 2021 gaihuiying - 4.9-10 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:fix build error with gcc 10 + * Wed Jun 30 2021 gaihuiying - 4.9-9 - Type:bugfix - ID:NA