- Add uninit.patch.

OBS-URL: https://build.opensuse.org/package/show/server:http/varnish?expand=0&rev=95
This commit is contained in:
Jan Engelhardt 2019-08-26 12:35:16 +00:00 committed by Git OBS Bridge
parent 4e9dfa9443
commit 72d601657e
3 changed files with 36 additions and 1 deletions

29
uninit.patch Normal file
View File

@ -0,0 +1,29 @@
From: Jan Engelhardt <jengelh@inai.de>
Date: 2019-08-26 14:13:15.685236019 +0200
varnish screwing itself by use of -Werror.
[ 34s] vtc_haproxy.c: In function 'haproxy_start':
[ 34s] vtc_haproxy.c:442:10: error: 'pid' may be used uninitialized in this function [-Werror=maybe-uninitialized]
[ 34s] 442 | h->pid = pid;
[ 34s] | ^
[ 34s] vtc_haproxy.c:413:8: note: 'pid' was declared here
[ 34s] 413 | pid_t pid;
---
bin/varnishtest/vtc_haproxy.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: varnish-6.2.0/bin/varnishtest/vtc_haproxy.c
===================================================================
--- varnish-6.2.0.orig/bin/varnishtest/vtc_haproxy.c
+++ varnish-6.2.0/bin/varnishtest/vtc_haproxy.c
@@ -410,7 +410,7 @@ haproxy_wait_pidfile(struct haproxy *h)
char buf_err[1024] = {0};
int usleep_time = 1000;
double t0;
- pid_t pid;
+ pid_t pid = 0;
vtc_log(h->vl, 3, "wait-pid-file");
for (t0 = VTIM_mono(); VTIM_mono() - t0 < 3;) {

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Mon Aug 26 10:52:05 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
- Add uninit.patch.
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Mar 27 10:01:08 UTC 2019 - Samu Voutilainen <smar@smar.fi> Wed Mar 27 10:01:08 UTC 2019 - Samu Voutilainen <smar@smar.fi>

View File

@ -40,6 +40,7 @@ Source5: varnish.logrotate
Source7: varnish.service Source7: varnish.service
Source8: varnishlog.service Source8: varnishlog.service
Patch1: varnish-5.1.2-add-fallthrough-comments.patch Patch1: varnish-5.1.2-add-fallthrough-comments.patch
Patch2: uninit.patch
BuildRequires: python3-docutils BuildRequires: python3-docutils
BuildRequires: python3-Sphinx BuildRequires: python3-Sphinx
BuildRequires: libxslt BuildRequires: libxslt
@ -98,7 +99,7 @@ This package holds the development files for varnish.
%autosetup -p1 %autosetup -p1
%build %build
export CFLAGS="%optflags -fstack-protector -Wno-error=clobbered" export CFLAGS="%optflags -fstack-protector -Wno-error=clobbered -Werror=maybe-uninitialized"
%ifarch %ix86 %ifarch %ix86
export CFLAGS="$CFLAGS -ffloat-store -fexcess-precision=standard" export CFLAGS="$CFLAGS -ffloat-store -fexcess-precision=standard"
%endif %endif