summaryrefslogtreecommitdiffstats
path: root/net/tipc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-08 03:21:38 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-08 03:21:38 +0000
commit9351405e44641037ccff29c0d88d92c0617b5088 (patch)
treedfee90e28394ae31df1033696f8656add6c4fc26 /net/tipc
parentReleasing progress-linux version 4.19.249-2progress5u1. (diff)
downloadlinux-9351405e44641037ccff29c0d88d92c0617b5088.tar.xz
linux-9351405e44641037ccff29c0d88d92c0617b5088.zip
Merging upstream version 4.19.260.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'net/tipc')
-rw-r--r--net/tipc/monitor.c2
-rw-r--r--net/tipc/socket.c1
2 files changed, 2 insertions, 1 deletions
diff --git a/net/tipc/monitor.c b/net/tipc/monitor.c
index 7b6c1c5c3..0268857a3 100644
--- a/net/tipc/monitor.c
+++ b/net/tipc/monitor.c
@@ -130,7 +130,7 @@ static void map_set(u64 *up_map, int i, unsigned int v)
static int map_get(u64 up_map, int i)
{
- return (up_map & (1 << i)) >> i;
+ return (up_map & (1ULL << i)) >> i;
}
static struct tipc_peer *peer_prev(struct tipc_peer *peer)
diff --git a/net/tipc/socket.c b/net/tipc/socket.c
index 6c18b4565..8266452c1 100644
--- a/net/tipc/socket.c
+++ b/net/tipc/socket.c
@@ -453,6 +453,7 @@ static int tipc_sk_create(struct net *net, struct socket *sock,
sock_init_data(sock, sk);
tipc_set_sk_state(sk, TIPC_OPEN);
if (tipc_sk_insert(tsk)) {
+ sk_free(sk);
pr_warn("Socket create failed; port number exhausted\n");
return -EINVAL;
}