mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
xtables-addons: fix build on 4.19 for xt_DNETMAP and xt_pknock
Backport 2 commits to fix build on 4.19: https://github.com/nawawi/xtables-addons/commit/3ea761a1ed338241fbc79bef8e433307e108b6cd https://github.com/nawawi/xtables-addons/commit/2b76b68c65c97fc11409088c3c30993324df8500 Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
From 3ea761a1ed338241fbc79bef8e433307e108b6cd Mon Sep 17 00:00:00 2001
|
||||
From: Jan Engelhardt <jengelh@inai.de>
|
||||
Date: Tue, 14 Aug 2018 14:29:30 +0200
|
||||
Subject: [PATCH] build: add support for Linux 4.18
|
||||
|
||||
---
|
||||
extensions/xt_DNETMAP.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/extensions/xt_DNETMAP.c b/extensions/xt_DNETMAP.c
|
||||
index 1b415c3..de7d4ec 100644
|
||||
--- a/extensions/xt_DNETMAP.c
|
||||
+++ b/extensions/xt_DNETMAP.c
|
||||
@@ -367,7 +367,11 @@ dnetmap_tg(struct sk_buff *skb, const struct xt_action_param *par)
|
||||
__be32 prenat_ip, postnat_ip, prenat_ip_prev;
|
||||
const struct xt_DNETMAP_tginfo *tginfo = par->targinfo;
|
||||
const struct nf_nat_range *mr = &tginfo->prefix;
|
||||
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 18, 0)
|
||||
+ struct nf_nat_range2 newrange;
|
||||
+#else
|
||||
struct nf_nat_range newrange;
|
||||
+#endif
|
||||
struct dnetmap_entry *e;
|
||||
struct dnetmap_prefix *p;
|
||||
__s32 jttl;
|
||||
Reference in New Issue
Block a user