Blame SOURCES/0001-mptcpize-force-MPTCP-usage-for-IPPROTO_IP-too-159.patch

0c0d28
From 5633f08e35552295b2f9414ff32ca4e8e081b2f2 Mon Sep 17 00:00:00 2001
0c0d28
Message-Id: <5633f08e35552295b2f9414ff32ca4e8e081b2f2.1638196305.git.dcaratti@redhat.com>
0c0d28
From: Paolo Abeni <paolo.abeni@gmail.com>
0c0d28
Date: Tue, 12 Oct 2021 19:24:33 +0200
0c0d28
Subject: [PATCH] mptcpize: force MPTCP usage for IPPROTO_IP, too (#159)
0c0d28
0c0d28
The current ignores calls alike:
0c0d28
0c0d28
	socket(AF_INET, SOCK_STREAM, IPPROTO_IP)
0c0d28
0c0d28
We should hijack them, too.
0c0d28
---
0c0d28
 src/mptcpwrap.c | 2 +-
0c0d28
 1 file changed, 1 insertion(+), 1 deletion(-)
0c0d28
0c0d28
diff --git a/src/mptcpwrap.c b/src/mptcpwrap.c
0c0d28
index 37b0545..1aaf00f 100644
0c0d28
--- a/src/mptcpwrap.c
0c0d28
+++ b/src/mptcpwrap.c
0c0d28
@@ -27,7 +27,7 @@ int __attribute__((visibility("default"))) socket(int family, int type, int prot
0c0d28
 		goto do_socket;
0c0d28
 
0c0d28
 	// socket(AF_INET, SOCK_STREM, 0) maps to TCP, too
0c0d28
-	if (protocol == 0 && protocol != IPPROTO_TCP)
0c0d28
+	if (protocol != 0 && protocol != IPPROTO_TCP)
0c0d28
 		goto do_socket;
0c0d28
 
0c0d28
 	protocol = IPPROTO_TCP + 256;
0c0d28
-- 
0c0d28
2.31.1
0c0d28