bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#61708: 28.2; file-modes-symbolic-to-number inconsistency


From: Thierry Volpiatto
Subject: bug#61708: 28.2; file-modes-symbolic-to-number inconsistency
Date: Wed, 22 Feb 2023 14:16:53 +0000

Here a simple patch to summarize what's wrong:

diff --git a/lisp/files.el b/lisp/files.el
index 5b989902bc3..576eb22c49f 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -8363,6 +8363,7 @@ If CHAR is in [Xugo], the value is taken from FROM (or 0 
if omitted)."
   (cond ((eq char ?r) #o0444)
        ((eq char ?w) #o0222)
        ((eq char ?x) #o0111)
+        ((eq char ?-) #o0000)
        ((eq char ?s) #o6000)
        ((eq char ?t) #o1000)
        ;; Rights relative to the previous file modes.
@@ -8393,7 +8394,7 @@ as in \"og+rX-w\"."
       (let ((num-right 0)
            char-right)
        (while (memq (setq char-right (pop list-rights))
-                    '(?r ?w ?x ?X ?s ?t ?u ?g ?o))
+                    '(?r ?w ?x ?X ?s ?t ?u ?g ?o ?-))
          (setq num-right
                (logior num-right
                        (file-modes-char-to-right char-right num-rights))))

-- 
Thierry

Attachment: signature.asc
Description: PGP signature


reply via email to

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