b05147c356
Change patch format to remove Git version * Patches 0001-0122 only have the patch format modified Update to the head of the upstream staging branch plus redhat patches * Patches 0123-0134 & 1036-0142 are from the upstream staging branch * Patches 0143-1046 have been submitted upstream * Patch 0156 is a Red Hat only patch. Red Hat udev rules set ID_SERIAL from 60-persistent-storage.rules instead of 55-scsi-sg3_id.rules. Multipath's parse_vpd_pg83() function needs to match the ID_SERIAL value from udev. Rename files * Previous patches 0123-0132 are now patches 1035 & 0147-0155
53 lines
1.9 KiB
Diff
53 lines
1.9 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Martin Wilck <mwilck@suse.com>
|
|
Date: Wed, 10 Feb 2021 13:15:17 +0100
|
|
Subject: [PATCH] multipath-tools tests: fix stringop-overflow build errors
|
|
with gcc 11
|
|
|
|
gcc-11 throws an error compiling alias.c and dmevents.c:
|
|
|
|
In file included from ../libmultipath/checkers.h:4,
|
|
from ../libmultipath/prio.h:7,
|
|
from ../libmultipath/structs.h:8,
|
|
from dmevents.c:29:
|
|
../multipathd/dmevents.c: In function 'dmevent_loop':
|
|
../multipathd/dmevents.c:357:17: error: '__sigsetjmp' accessing 200 bytes in a region of size 72 [-Werror=stringop-overflow=]
|
|
357 | pthread_cleanup_push(cleanup_lock, &waiter->vecs->lock);
|
|
| ^~~~~~~~~~~~~~~~~~~~
|
|
../multipathd/dmevents.c:357:17: note: referencing argument 1 of type 'struct __jmp_buf_tag *'
|
|
/usr/include/pthread.h:734:12: note: in a call to function '__sigsetjmp'
|
|
734 | extern int __sigsetjmp (struct __jmp_buf_tag *__env, int __savemask) __THROWNL;
|
|
| ^~~~~~~~~~~
|
|
|
|
The reason seems to be a mismatch between the __sigsetjmp() prototype
|
|
in <setjmp.h> and <pthread.h>. The error is encountered iUntil this is fixed in the toolchain,
|
|
work around it by including <pthread.h> before <setjmp.h>.
|
|
|
|
Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
|
|
---
|
|
tests/alias.c | 1 +
|
|
tests/dmevents.c | 1 +
|
|
2 files changed, 2 insertions(+)
|
|
|
|
diff --git a/tests/alias.c b/tests/alias.c
|
|
index 0311faa6..5e0bfea3 100644
|
|
--- a/tests/alias.c
|
|
+++ b/tests/alias.c
|
|
@@ -1,3 +1,4 @@
|
|
+#include <pthread.h>
|
|
#include <stdint.h>
|
|
#include <setjmp.h>
|
|
#include <stdio.h>
|
|
diff --git a/tests/dmevents.c b/tests/dmevents.c
|
|
index b7c5122b..29eaa6db 100644
|
|
--- a/tests/dmevents.c
|
|
+++ b/tests/dmevents.c
|
|
@@ -16,6 +16,7 @@
|
|
*
|
|
*/
|
|
|
|
+#include <pthread.h>
|
|
#include <stdint.h>
|
|
#include <stdbool.h>
|
|
#include <stdarg.h>
|