From 040ec3f66764742d7bfec65886fc8e90291e146a Mon Sep 17 00:00:00 2001
From: Stefano Brivio <sbrivio@redhat.com>
Date: Fri, 17 Feb 2023 14:07:31 +0000
Subject: [PATCH] Revert "Fix C99 compatibility issue"

This reverts commit e9e9dec33aebe8d6be32008661c9b2fc47b67cb7: the C99
compatibility issue has been fixed upstream.
---
 passt-c99.patch | 18 ------------------
 passt.spec      |  8 ++------
 2 files changed, 2 insertions(+), 24 deletions(-)
 delete mode 100644 passt-c99.patch

diff --git a/passt-c99.patch b/passt-c99.patch
deleted file mode 100644
index 7bd2f09..0000000
--- a/passt-c99.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Avoid an implicit int, to prevent build failures with future compilers.
-
-Submitted upstream: <https://bugs.passt.top/show_bug.cgi?id=42>
-
-
-diff --git a/Makefile b/Makefile
-index 1dc2df5884d3b597..cd62900e7406e155 100644
---- a/Makefile
-+++ b/Makefile
-@@ -95,7 +95,7 @@ ifeq ($(shell :|$(CC) -fstack-protector-strong -S -xc - -o - >/dev/null 2>&1; ec
- 	FLAGS += -fstack-protector-strong
- endif
- 
--C := \#define _GNU_SOURCE\n\#include <fcntl.h>\nx = FALLOC_FL_COLLAPSE_RANGE;
-+C := \#define _GNU_SOURCE\n\#include <fcntl.h>\nint x = FALLOC_FL_COLLAPSE_RANGE;
- ifeq ($(shell printf "$(C)" | $(CC) -S -xc - -o - >/dev/null 2>&1; echo $$?),0)
- 	EXTRA_SYSCALLS += fallocate
- endif
diff --git a/passt.spec b/passt.spec
index 4c575e6..9191fc6 100644
--- a/passt.spec
+++ b/passt.spec
@@ -11,13 +11,12 @@
 
 Name:		passt
 Version:	0^20221116.gace074c
-Release:	3%{?dist}
+Release:	2%{?dist}
 Summary:	User-mode networking daemons for virtual machines and namespaces
 License:	AGPLv3+ and BSD
 Group:		System Environment/Daemons
 URL:		https://passt.top/
 Source:		https://passt.top/passt/snapshot/passt-%{git_hash}.tar.xz
-Patch0: passt-c99.patch
 
 BuildRequires:	gcc, make, checkpolicy, selinux-policy-devel
 
@@ -46,7 +45,7 @@ Requires(preun): policycoreutils
 This package adds SELinux enforcement to passt(1) and pasta(1).
 
 %prep
-%autosetup -p1 -n passt-%{git_hash}
+%setup -q -n passt-%{git_hash}
 
 %build
 %set_build_flags
@@ -97,9 +96,6 @@ semodule -r pasta 2>/dev/null || :
 %{_datadir}/selinux/packages/%{name}/pasta.pp
 
 %changelog
-* Fri Feb 03 2023 Florian Weimer <fweimer@redhat.com> - 0^20221116.gace074c-3
-- Fix C99 compatibility issue
-
 * Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0^20221116.gace074c-2
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild