]> git.proxmox.com Git - pve-kernel.git/blame - patches/kernel/0017-Revert-fortify-Do-not-cast-to-unsigned-char.patch
prepare for 6.2 release
[pve-kernel.git] / patches / kernel / 0017-Revert-fortify-Do-not-cast-to-unsigned-char.patch
CommitLineData
3ba39b6c
TL
1From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
2From: Thomas Lamprecht <t.lamprecht@proxmox.com>
3Date: Tue, 10 Jan 2023 08:52:40 +0100
4Subject: [PATCH] Revert "fortify: Do not cast to "unsigned char""
826eb0ff
FG
5MIME-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
3ba39b6c
TL
8
9This reverts commit 106b7a61c488d2022f44e3531ce33461c7c0685f.
10
11Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
826eb0ff 12Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
3ba39b6c
TL
13---
14 include/linux/fortify-string.h | 2 +-
15 1 file changed, 1 insertion(+), 1 deletion(-)
16
17diff --git a/include/linux/fortify-string.h b/include/linux/fortify-string.h
18index 5001a11258e4..1067a8450826 100644
19--- a/include/linux/fortify-string.h
20+++ b/include/linux/fortify-string.h
21@@ -18,7 +18,7 @@ void __write_overflow_field(size_t avail, size_t wanted) __compiletime_warning("
22
23 #define __compiletime_strlen(p) \
24 ({ \
25- char *__p = (char *)(p); \
26+ unsigned char *__p = (unsigned char *)(p); \
27 size_t __ret = SIZE_MAX; \
28 size_t __p_size = __member_size(p); \
29 if (__p_size != SIZE_MAX && \