bug-mes
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

The definition of S_ISUID is wrong


From: Dor Askayo
Subject: The definition of S_ISUID is wrong
Date: Mon, 9 May 2022 01:54:19 +0300

This causes all sorts of problems in regards to file permissions when using
various commands such as "ls", "cp" and "chmod".

See the patch below for the simple fix.

Thanks,
Dor

>From 75f253434b745883503c1a280095fa75f0d3b327 Mon Sep 17 00:00:00 2001
From: Dor Askayo <dor.askayo@gmail.com>
Date: Sat, 1 Jan 2022 20:38:38 +0200
Subject: [PATCH] mescc: Fix definition of S_ISUID

* include/sys/stat.h (S_ISUID): Fix value.
---
 include/sys/stat.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/sys/stat.h b/include/sys/stat.h
index adc75f21..81674a03 100644
--- a/include/sys/stat.h
+++ b/include/sys/stat.h
@@ -107,7 +107,7 @@ int stat (char const *file_name, struct stat *buf);
 #define S_IWUSR 00200
 #define S_IRUSR 00400

-#define S_ISUID 0400
+#define S_ISUID 04000
 #define S_ISGID 02000
 #define S_IXGRP 00010
 #define S_IXOTH 00001
-- 
2.35.1



reply via email to

[Prev in Thread] Current Thread [Next in Thread]