|
|
621646 |
From fe1ac5eaa8ae482c9112aed6b89f9f2e529f4516 Mon Sep 17 00:00:00 2001
|
|
|
621646 |
From: Phil Sutter <psutter@redhat.com>
|
|
|
621646 |
Date: Tue, 10 Dec 2019 12:27:13 +0100
|
|
|
621646 |
Subject: [PATCH] uapi: netfilter: Avoid undefined left-shift in xt_sctp.h
|
|
|
621646 |
|
|
|
621646 |
This is a backport of kernel commit 164166558aace ("netfilter: uapi:
|
|
|
621646 |
Avoid undefined left-shift in xt_sctp.h").
|
|
|
621646 |
|
|
|
621646 |
Signed-off-by: Phil Sutter <psutter@redhat.com>
|
|
|
621646 |
---
|
|
|
621646 |
include/linux/netfilter/xt_sctp.h | 6 +++---
|
|
|
621646 |
1 file changed, 3 insertions(+), 3 deletions(-)
|
|
|
621646 |
|
|
|
621646 |
diff --git a/include/linux/netfilter/xt_sctp.h b/include/linux/netfilter/xt_sctp.h
|
|
|
621646 |
index a501e6196905d..5b28525a2482a 100644
|
|
|
621646 |
--- a/include/linux/netfilter/xt_sctp.h
|
|
|
621646 |
+++ b/include/linux/netfilter/xt_sctp.h
|
|
|
621646 |
@@ -40,19 +40,19 @@ struct xt_sctp_info {
|
|
|
621646 |
#define SCTP_CHUNKMAP_SET(chunkmap, type) \
|
|
|
621646 |
do { \
|
|
|
621646 |
(chunkmap)[type / bytes(__u32)] |= \
|
|
|
621646 |
- 1 << (type % bytes(__u32)); \
|
|
|
621646 |
+ 1u << (type % bytes(__u32)); \
|
|
|
621646 |
} while (0)
|
|
|
621646 |
|
|
|
621646 |
#define SCTP_CHUNKMAP_CLEAR(chunkmap, type) \
|
|
|
621646 |
do { \
|
|
|
621646 |
(chunkmap)[type / bytes(__u32)] &= \
|
|
|
621646 |
- ~(1 << (type % bytes(__u32))); \
|
|
|
621646 |
+ ~(1u << (type % bytes(__u32))); \
|
|
|
621646 |
} while (0)
|
|
|
621646 |
|
|
|
621646 |
#define SCTP_CHUNKMAP_IS_SET(chunkmap, type) \
|
|
|
621646 |
({ \
|
|
|
621646 |
((chunkmap)[type / bytes (__u32)] & \
|
|
|
621646 |
- (1 << (type % bytes (__u32)))) ? 1: 0; \
|
|
|
621646 |
+ (1u << (type % bytes (__u32)))) ? 1: 0; \
|
|
|
621646 |
})
|
|
|
621646 |
|
|
|
621646 |
#define SCTP_CHUNKMAP_RESET(chunkmap) \
|
|
|
621646 |
--
|
|
|
621646 |
2.24.0
|
|
|
621646 |
|