Avoid using implicit int C89 feature

Related to:

  <https://fedoraproject.org/wiki/Changes/PortingToModernC>
  <https://fedoraproject.org/wiki/Toolchain/PortingToModernC>
This commit is contained in:
Florian Weimer 2022-11-18 19:55:54 +01:00
parent abb597e9d8
commit d38884287b
2 changed files with 24 additions and 1 deletions

View File

@ -0,0 +1,17 @@
Add the missing int, to avoid a compilation failure in strict C99 mode.
Submitted upstream: <https://bugs.kde.org/show_bug.cgi?id=462007>
diff --git a/none/tests/faultstatus.c b/none/tests/faultstatus.c
index 458ea8264593af4e..92a8350ab2285092 100644
--- a/none/tests/faultstatus.c
+++ b/none/tests/faultstatus.c
@@ -190,7 +190,7 @@ int main()
return 0;
}
-static volatile s_zero;
+static volatile int s_zero;
static int zero()
{

View File

@ -3,7 +3,7 @@
Summary: Dynamic analysis tools to detect memory or thread bugs and profile
Name: %{?scl_prefix}valgrind
Version: 3.20.0
Release: 1%{?dist}
Release: 2%{?dist}
Epoch: 1
License: GPLv2+
URL: https://www.valgrind.org/
@ -83,6 +83,8 @@ Patch3: valgrind-3.16.0-some-stack-protector.patch
# Add some -Wl,z,now.
Patch4: valgrind-3.16.0-some-Wl-z-now.patch
Patch5: valgrind-faultstatus-implicit-int.patch
BuildRequires: make
BuildRequires: glibc-devel
@ -218,6 +220,7 @@ Valgrind User Manual for details.
%if 0%{?fedora} || 0%{?rhel} >= 7
%patch3 -p1
%patch4 -p1
%patch5 -p1
%endif
%build
@ -448,6 +451,9 @@ fi
%endif
%changelog
* Fri Nov 18 2022 Florian Weimer <fweimer@redhat.com> - 1:3.20.0-2
- Avoid using implicit int C89 feature
* Mon Oct 24 2022 Mark Wielaard <mjw@fedoraproject.org> - 3.20.0-1
- Upgrade to valgrind 3.20.0. Drop old patches.