From unknown Thu Aug 14 18:39:40 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#50189 <50189@debbugs.gnu.org> To: bug#50189 <50189@debbugs.gnu.org> Subject: Status: wdired chmod should not follow symlinks (Bug#11912 followup) Reply-To: bug#50189 <50189@debbugs.gnu.org> Date: Fri, 15 Aug 2025 01:39:40 +0000 retitle 50189 wdired chmod should not follow symlinks (Bug#11912 followup) reassign 50189 emacs submitter 50189 Paul Eggert severity 50189 normal tag 50189 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 24 14:05:06 2021 Received: (at submit) by debbugs.gnu.org; 24 Aug 2021 18:05:06 +0000 Received: from localhost ([127.0.0.1]:45157 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIanH-0004Rw-1K for submit@debbugs.gnu.org; Tue, 24 Aug 2021 14:05:06 -0400 Received: from lists.gnu.org ([209.51.188.17]:52994) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIanB-0004RP-Le for submit@debbugs.gnu.org; Tue, 24 Aug 2021 14:05:01 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43050) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mIanB-0001wb-GE for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 14:04:57 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:42310) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mIan9-0004DE-CT for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 14:04:57 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id D093716005A for ; Tue, 24 Aug 2021 11:04:52 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id UZGGBHEJ0o4w for ; Tue, 24 Aug 2021 11:04:48 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 2525B1600BB for ; Tue, 24 Aug 2021 11:04:48 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id P79XqSzyLB9c for ; Tue, 24 Aug 2021 11:04:48 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 0137416005A for ; Tue, 24 Aug 2021 11:04:47 -0700 (PDT) To: Emacs bug reports and feature requests From: Paul Eggert Subject: wdired chmod should not follow symlinks Organization: UCLA Computer Science Department Message-ID: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> Date: Tue, 24 Aug 2021 11:04:47 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------1C8A237C3E2690677B35D53F" Content-Language: en-US Received-SPF: pass client-ip=131.179.128.68; envelope-from=eggert@cs.ucla.edu; helo=zimbra.cs.ucla.edu X-Spam_score_int: -22 X-Spam_score: -2.3 X-Spam_bar: -- X-Spam_report: (-2.3 / 5.0 requ) RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) This is a multi-part message in MIME format. --------------1C8A237C3E2690677B35D53F Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit To be consistent with dired M, wdired's method of textually editing a symlink's permissions should also not follow symlinks. Proposed patch attached. I did not test this, as I don't use wdired and couldn't get it to work for me regardless of whether the patch is applied. This patch also removes some obsolete commentary about dired-chmod-program. --------------1C8A237C3E2690677B35D53F Content-Type: text/x-patch; charset=UTF-8; name="0001-Make-wdired-match-dired-with-symlink-permissions.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename*0="0001-Make-wdired-match-dired-with-symlink-permissions.patch" >From 9b31a8ea5a919d67c6e78706b1b86ffbdf336e11 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Tue, 24 Aug 2021 11:00:52 -0700 Subject: [PATCH] Make wdired match dired with symlink permissions * lisp/wdired.el (wdired-do-perm-changes): Do not follow symlinks, to be consistent with plain dired. --- lisp/wdired.el | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/lisp/wdired.el b/lisp/wdired.el index fd549bac32..70dfd2c80a 100644 --- a/lisp/wdired.el +++ b/lisp/wdired.el @@ -45,8 +45,7 @@ ;; ;; - Change the target of symbolic links. ;; -;; - Change the permission bits of the filenames (in systems with a -;; working unix-alike `dired-chmod-program'). See and customize the +;; - Change the permission bits of the filenames. See and customize the ;; variable `wdired-allow-to-change-permissions'. To change a single ;; char (toggling between its two more usual values) you can press ;; the space bar over it or left-click the mouse. To set any char to @@ -125,10 +124,7 @@ wdired-allow-to-change-permissions If `advanced', the bits are freely editable. You can use `string-rectangle', `query-replace', etc. You can put any value (even newlines), but if you want your changes to be useful, you better put a -intelligible value. - -Anyway, the real change of the permissions is done by the external -program `dired-chmod-program', which must exist." +intelligible value." :type '(choice (const :tag "Not allowed" nil) (const :tag "Toggle/set bits" t) (other :tag "Bits freely editable" advanced))) @@ -995,7 +991,8 @@ wdired-do-perm-changes (setq filename (wdired-get-filename nil t)) (if (= (length perms-new) 10) (condition-case nil - (set-file-modes filename (wdired-perms-to-number perms-new)) + (set-file-modes filename (wdired-perms-to-number perms-new) + 'nofollow) (error (setq errors (1+ errors)) (dired-log "Setting mode of `%s' to `%s' failed\n\n" -- 2.31.1 --------------1C8A237C3E2690677B35D53F-- From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 24 17:41:35 2021 Received: (at control) by debbugs.gnu.org; 24 Aug 2021 21:41:35 +0000 Received: from localhost ([127.0.0.1]:45336 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIeAp-0001eG-DI for submit@debbugs.gnu.org; Tue, 24 Aug 2021 17:41:35 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:44966) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIeAm-0001dv-VO for control@debbugs.gnu.org; Tue, 24 Aug 2021 17:41:33 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id AD1B516007F for ; Tue, 24 Aug 2021 14:41:24 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id mapfBAXMqN-g for ; Tue, 24 Aug 2021 14:41:23 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id CA5FB1600BC for ; Tue, 24 Aug 2021 14:41:23 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id KrQ93dOMjwMQ for ; Tue, 24 Aug 2021 14:41:23 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id AAC4F16007F for ; Tue, 24 Aug 2021 14:41:23 -0700 (PDT) To: control@debbugs.gnu.org From: Paul Eggert Subject: 50189 has a patch Organization: UCLA Computer Science Department Message-ID: Date: Tue, 24 Aug 2021 14:41:23 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) tags 50189 patch From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 24 17:48:01 2021 Received: (at control) by debbugs.gnu.org; 24 Aug 2021 21:48:01 +0000 Received: from localhost ([127.0.0.1]:45341 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIeH3-0003w8-1C for submit@debbugs.gnu.org; Tue, 24 Aug 2021 17:48:01 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:45784) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIeH1-0003vs-6g for control@debbugs.gnu.org; Tue, 24 Aug 2021 17:48:00 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 8F91C16007F for ; Tue, 24 Aug 2021 14:47:52 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id rRS_1ZaOYp77 for ; Tue, 24 Aug 2021 14:47:51 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 37F051600BC for ; Tue, 24 Aug 2021 14:47:51 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id qt2PU2azQhbb for ; Tue, 24 Aug 2021 14:47:51 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 1B02416007F for ; Tue, 24 Aug 2021 14:47:51 -0700 (PDT) To: control@debbugs.gnu.org From: Paul Eggert Subject: retitle 50189 Organization: UCLA Computer Science Department Message-ID: <13ee25ee-fd7a-822f-ad78-f09c48e5520c@cs.ucla.edu> Date: Tue, 24 Aug 2021 14:47:50 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) retitle 50189 wdired chmod should not follow symlinks (Bug#11912 followup) From debbugs-submit-bounces@debbugs.gnu.org Wed Aug 25 07:47:49 2021 Received: (at 50189) by debbugs.gnu.org; 25 Aug 2021 11:47:49 +0000 Received: from localhost ([127.0.0.1]:45961 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIrNg-00055R-O3 for submit@debbugs.gnu.org; Wed, 25 Aug 2021 07:47:49 -0400 Received: from quimby.gnus.org ([95.216.78.240]:35626) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIrNb-0004x7-9T for 50189@debbugs.gnu.org; Wed, 25 Aug 2021 07:47:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=i+d7SbwYHpmyHHzpv8QLDnBR8kaN4BufF24cMb3VFHY=; b=c8glxjJp21zX5ie4jL5MpCHxSR IqDBl722lJIx5P1D4HdZuxD/IYKpOrT2dHvYjrJhHDaRcGR6QYPc5UGS8kiFuuuVmUTlWoknBBLQV NpiLS84gCDgZaraU5YFklfRW78V7K2V+Kaj/7B0EgmqgeBeW5PgyQ4M3QcSWGZ4HIY+w=; Received: from [84.212.220.105] (helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mIrNQ-0003i2-Cf; Wed, 25 Aug 2021 13:47:32 +0200 From: Lars Ingebrigtsen To: Paul Eggert Subject: Re: bug#50189: wdired chmod should not follow symlinks (Bug#11912 followup) References: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> Date: Wed, 25 Aug 2021 13:47:27 +0200 In-Reply-To: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> (Paul Eggert's message of "Tue, 24 Aug 2021 11:04:47 -0700") Message-ID: <87pmu1kapc.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Paul Eggert writes: > I did not test this, as I don't use wdired and couldn't get it to work > for me regardless of whether the patch is applied. Yeah, editing the permissions doesn't seem to work for me in dired. If I start with Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50189 Cc: 50189@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Paul Eggert writes: > I did not test this, as I don't use wdired and couldn't get it to work > for me regardless of whether the patch is applied. Yeah, editing the permissions doesn't seem to work for me in dired. If I start with -rw-r--r-- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG and press DEL after the final dash, it'll delete the dash and then say "Text is read only", leaving me with: -rw-r--r- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG And then I can't insert anything there, because it's now read-only. So something is wonky in the way wdired tries to make certain bits of the line read-only. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 10 02:21:15 2022 Received: (at 50189) by debbugs.gnu.org; 10 Sep 2022 06:21:15 +0000 Received: from localhost ([127.0.0.1]:36375 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oWtre-0006wo-Pv for submit@debbugs.gnu.org; Sat, 10 Sep 2022 02:21:15 -0400 Received: from quimby.gnus.org ([95.216.78.240]:55014) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oWtrc-0006wa-Ea for 50189@debbugs.gnu.org; Sat, 10 Sep 2022 02:21:13 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:Date:References: In-Reply-To:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=nc+NUMH412XvDxyT1Sxa7ej/75cha9Ojz7HE91kzzvM=; b=ojnZkSdkdQlmktiK+Aio8I5LL1 JaEYAt1zBNjgeF2Mm2pPzOIT4EjXCSeLCRMsoX2A6yQicd30diJIdh+lBEJcR/8Le9tNqFAmjOWYJ Bif1LQvDwSYInCItaYja1OZuo3kPDezgJw/kjVAfqKuezf2K7Cwb4hkhbDQZWdm855+c=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oWtrT-000780-If; Sat, 10 Sep 2022 08:21:05 +0200 From: Lars Ingebrigtsen To: Paul Eggert Subject: Re: bug#50189: wdired chmod should not follow symlinks (Bug#11912 followup) In-Reply-To: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> (Paul Eggert's message of "Tue, 24 Aug 2021 11:04:47 -0700") References: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> X-Now-Playing: Joe Jackson's _Beat Crazy_: "Someone Up There" Date: Sat, 10 Sep 2022 08:21:03 +0200 Message-ID: <87h71foils.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Paul Eggert writes: > To be consistent with dired M, wdired's method of textually editing a > symlink's permissions should also not follow symlinks. Proposed patch > attached. The patch looks "obviously correct", so I've applied it to Emacs 29. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50189 Cc: 50189@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Paul Eggert writes: > To be consistent with dired M, wdired's method of textually editing a > symlink's permissions should also not follow symlinks. Proposed patch > attached. The patch looks "obviously correct", so I've applied it to Emacs 29. From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 10 02:28:14 2022 Received: (at 50189) by debbugs.gnu.org; 10 Sep 2022 06:28:14 +0000 Received: from localhost ([127.0.0.1]:36394 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oWtyQ-00077Q-Gs for submit@debbugs.gnu.org; Sat, 10 Sep 2022 02:28:14 -0400 Received: from quimby.gnus.org ([95.216.78.240]:55084) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oWtyO-000778-H5 for 50189@debbugs.gnu.org; Sat, 10 Sep 2022 02:28:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:Date:References: In-Reply-To:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=J95z5fvmvjHoXp543No47DnIbwY2O4gAoVtwxzH3bcI=; b=b6mbu0zUhgzCpPZvnJoJHR4jSj nX4z0O/tHL3I/xucDFDLgaPr4YKDuWx1uCaojo2nrJ73rUhbxN7ol2piLmbD+Rbs2zVCecoW6ql9U OKOWLdT1V7ZkQfXix86vlRARGZgUMA9pqDp+hwLUNju0eWcYFUkRu1wOYvG3aEXv1yjM=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oWtyF-0007By-HB; Sat, 10 Sep 2022 08:28:05 +0200 From: Lars Ingebrigtsen To: Paul Eggert Subject: Re: bug#50189: wdired chmod should not follow symlinks (Bug#11912 followup) In-Reply-To: <87pmu1kapc.fsf@gnus.org> (Lars Ingebrigtsen's message of "Wed, 25 Aug 2021 13:47:27 +0200") References: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> <87pmu1kapc.fsf@gnus.org> X-Now-Playing: Joe Jackson's _Beat Crazy_: "Biology" Date: Sat, 10 Sep 2022 08:28:02 +0200 Message-ID: <87czc3oia5.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Lars Ingebrigtsen writes: > Yeah, editing the permissions doesn't seem to work for me in dired. If > I start with > > -rw-r--r-- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG > > and press DEL after the final dash, it'll delete [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50189 Cc: 50189@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Lars Ingebrigtsen writes: > Yeah, editing the permissions doesn't seem to work for me in dired. If > I start with > > -rw-r--r-- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG > > and press DEL after the final dash, it'll delete the dash and then say > "Text is read only", leaving me with: > > -rw-r--r- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG > > And then I can't insert anything there, because it's now read-only. So > something is wonky in the way wdired tries to make certain bits of the > line read-only. Setting wdired-allow-to-change-permissions to t or `advanced' made this work -- you can't really edit the permissions without that. So I guess there's nothing more to be done here... From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 10 02:28:19 2022 Received: (at control) by debbugs.gnu.org; 10 Sep 2022 06:28:19 +0000 Received: from localhost ([127.0.0.1]:36397 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oWtyU-00077g-QO for submit@debbugs.gnu.org; Sat, 10 Sep 2022 02:28:19 -0400 Received: from quimby.gnus.org ([95.216.78.240]:55098) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oWtyT-00077H-A7 for control@debbugs.gnu.org; Sat, 10 Sep 2022 02:28:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=4VeDm+4L9H1NobTxgxV1ltjvjbj6lCh6HmIyfCFiAy0=; b=bgSPypMCu05YBadakM8qUselIy B+Hi8QMc7qbp8WWTOimGIIlSO3C+BPPsxBnpNDFBbWEsNoKBaVRkIcMAs55bLo+QU/9KK5X2s6yVN QcHrSxCOIzxydYtGnwEger/yN9rPLbqJ7RrViZyF2OUBnAr9rJSCN1QbKGklW5f7c4RM=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oWtyL-0007C8-MT for control@debbugs.gnu.org; Sat, 10 Sep 2022 08:28:11 +0200 Date: Sat, 10 Sep 2022 08:28:09 +0200 Message-Id: <87bkrnoi9y.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #50189 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 50189 29.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) close 50189 29.1 quit From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 10 21:33:10 2022 Received: (at 50189) by debbugs.gnu.org; 11 Sep 2022 01:33:10 +0000 Received: from localhost ([127.0.0.1]:40530 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oXBqP-0002uc-KD for submit@debbugs.gnu.org; Sat, 10 Sep 2022 21:33:09 -0400 Received: from mout.web.de ([212.227.17.11]:34219) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oXBqM-0002u6-Ma for 50189@debbugs.gnu.org; Sat, 10 Sep 2022 21:33:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1662859965; bh=g0mqUhmn24IhRkDASJi/f6pzlU25n4mCOPwGI1dwMpA=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=GDFs1fDjaKA41Dlghh/vHhyT/7HvJXFrROwAPWREzTEz2liLF2FKz0ZKDu60q7HHC oIAXnOwGuZmvxgMvm9fBD/G48drVUiWv01tgcsVwJAEhtQC5xAnzwygpt1Y3lR8mgF kimjwCnnH9wquWRD/BcbVqGbZ5mKngoiecFPZsM8= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([92.208.190.67]) by smtp.web.de (mrweb106 [213.165.67.124]) with ESMTPSA (Nemesis) id 1MFJjP-1oZ3VE12Tp-00FSKb; Sun, 11 Sep 2022 03:32:45 +0200 From: Michael Heerdegen To: Lars Ingebrigtsen Subject: Re: bug#50189: wdired chmod should not follow symlinks (Bug#11912 followup) In-Reply-To: <87czc3oia5.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sat, 10 Sep 2022 08:28:02 +0200") References: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> <87pmu1kapc.fsf@gnus.org> <87czc3oia5.fsf@gnus.org> Date: Sun, 11 Sep 2022 03:32:42 +0200 Message-ID: <87mtb6zoed.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:EMp7sBroHGaE6xuJ0nIgPF7WRvweDzQ2twtTWPPIE/U+Fkf+Urd GtWsY2WLcKXYnr3Ak8/wodWQgqMW/pifdWXeJB5SK9u0i3d87LAQEnNee+ndUB7Akv2JFS8 P4YO+cKLJYfQSZuDh+37WJpCqq6jCivbcTyS1W13F7SX/p9bG8hAOGCddhfjAH0M2eXouih Wdva3gOF/glg5C1ocNBTg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:HIl947FPAg8=:p5YOZ+nO9EqoR5sbThu9qq /6wQ/mq2RkLz0TrlYOQk32dGdUZ0E9feu/UW4t8bznd9GtREoVonVrvFtQC1Tt000CD0r5FOd iWX5wnJKQNZyK3Gp/WKvr14aWhoUTysybRri5eU2kX9Tj+8+20X34U5YOMaYBDLbacwzsNTcQ yCR7Gikhvl7U9oCZAyambpmulG4Wf2bxVsO7/j6ySn7g6G9/5LDq2DqBc7c79xy1YYQV1p1EM GhFFLtu6WDOKoKvnwIlEBJhVn6HscrEarkL/7bcX3LR4/idJiksbL9cmiu2Uh6MizfARP8zMa 5KR2igcNegqBQtlIbZQHQHknZnX6QIkyJi3Db3zlyHxtaZ36pFf8wHV6Ol2m9fD+k1krp8kaj qYR07nDOi+NtyS2yKBLRo48ydt5yApWYTvjqQZkxnmJC6aY2xEK/EtRNo7SZi6DlY2AKeTvGO GG22SHjhXeraujsEx8C/vrR9A1FWHME3JsS/ogSEWTb22bqysMRJAu+p717ZjmhAjXdZbKSrU iPPRFLeCuYanLl9UfYGFP6f1jcRy5cc5HkSVKJE6XRycRtGP+87tqVdw/3OAZpYaLX34Vpy2x nZIsc6QuLw6sp7I6XHDxmjFJih2MTUvNFpjhb8e9h2dNfB1L2wdrqBuCsTIwDSw6REI6O4beC FmRPUDA18vbroW3de4+X9+tTtcDtS31skVwjfE6ev54dUjMxgUILjCG6L42pW3wOWJ3k6snGh 8iDWJDd3cvKAmjy/K41dlPC3MGmAqy/d/5D0/Flid3BWPCwjON7JLES0rpyiuMRabXLJSjJNp uG5aZxLLdjAeChC6TGQKKJ4W9pHte7D/1wVQKoZLZmC7XV9Q3tExq5a5NGadak7efz6Z0mZsS nqV7FEEdIgS+jVd5SdKJjwBQRMKugI+mXxfFbsbEE99yVXg1FvdCF/ljM0s+wSZXkFTs6ysjV 9NINaIU16De6UbH6TRgTZw2fA7E3jk5w5P2lLEythjKyQDy4zaOqBD49lNkDdob6SXZefEdCM O4GMsLcLzIp1iAZiuTCktv8Gkku7Ar/i+Hqmwvz5kVT3knmNdo/uwKL0H1xL7k/bGXZVvP86y PZ+iHmR+L/qe/BTBU5Q/jKK+KqyGKo0Yr3/VW1HINCL8+4iO3a51G90h9uIxKnrlEMy+7vsrZ w7WNWW7o4e4ZFrD5WNiPJgSYcw X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 50189 Cc: 50189@debbugs.gnu.org, Paul Eggert , Arthur Miller X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Lars Ingebrigtsen writes: > Lars Ingebrigtsen writes: > > > Yeah, editing the permissions doesn't seem to work for me in dired. If > > I start with > > > > -rw-r--r-- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG > > > > and press DEL after the final dash, it'll delete the dash and then say > > "Text is read only", leaving me with: > > > > -rw-r--r- 1 larsi larsi 329K Aug 21 18:22 IMG_4478.JPG > > > > And then I can't insert anything there, because it's now read-only. So > > something is wonky in the way wdired tries to make certain bits of the > > line read-only. > > Setting wdired-allow-to-change-permissions to t or `advanced' made this > work -- you can't really edit the permissions without that. That behavior not optimal and a bit confusing. As you might remember, text properties in wdired are now attached on the fly for better performance, implemented here: | 4dbc44550d * lisp/wdired.el: Apply text properties lazily | Arthur Miller 2021-03-27 [Arthur is CC'd] The problem in this case: the read-only property is attached in `before-change-functions'. But that doesn't prevent the change being performed. Try e.g. in *scratch*: #+begin_src emacs-lisp (add-hook 'before-change-functions (lambda (&rest _) (put-text-property (point-min) (point-max) 'read-only t)) nil t) #+end_src The first changes goes through although the text is already read-only, because it's still the same command or so (anyone thinking this is a bug?). I think we could make wdired explicitly check for and throw a "user-error" in this case so that the editing command is not performed (but only after the properties were attached). TIA, Michael. From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 11 07:05:44 2022 Received: (at 50189) by debbugs.gnu.org; 11 Sep 2022 11:05:44 +0000 Received: from localhost ([127.0.0.1]:40872 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oXKmW-0002l3-7x for submit@debbugs.gnu.org; Sun, 11 Sep 2022 07:05:44 -0400 Received: from quimby.gnus.org ([95.216.78.240]:39180) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oXKmV-0002kp-2W for 50189@debbugs.gnu.org; Sun, 11 Sep 2022 07:05:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:Date:References: In-Reply-To:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=PHtnpUPNi9xTqWssM+lLRDVlaebzqOd2elVoBexwbPI=; b=NCXttL3DZhHjQ5iDw68F9HV0m9 /ZOp719IYB9mYW/CtWSYL669pGGHQzGFF0cHUzgT5XmJ5Cm1C3x/vtj1B/+EQziSXykWMKf6aTxa5 uXljkUB/1CRzCDsxhLNfVZ/TF1vib1g9BCfsqzkoR0iV0nU/guqpZ8wqKOWR94nqNDJk=; Received: from [84.212.220.105] (helo=joga) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oXKmK-0003XH-Ue; Sun, 11 Sep 2022 13:05:34 +0200 From: Lars Ingebrigtsen To: Michael Heerdegen Subject: Re: bug#50189: wdired chmod should not follow symlinks (Bug#11912 followup) In-Reply-To: <87mtb6zoed.fsf@web.de> (Michael Heerdegen's message of "Sun, 11 Sep 2022 03:32:42 +0200") References: <55e059fe-c2ae-e8cb-20e2-30de656ce0a7@cs.ucla.edu> <87pmu1kapc.fsf@gnus.org> <87czc3oia5.fsf@gnus.org> <87mtb6zoed.fsf@web.de> X-Now-Playing: Insides's _Euphoria_: "Distractions" Date: Sun, 11 Sep 2022 13:05:32 +0200 Message-ID: <87o7vmgohv.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Michael Heerdegen writes: >> Setting wdired-allow-to-change-permissions to t or `advanced' made this >> work -- you can't really edit the permissions without that. > > That behavior not optimal and a bit confusing. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50189 Cc: 50189@debbugs.gnu.org, Paul Eggert , Arthur Miller X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Michael Heerdegen writes: >> Setting wdired-allow-to-change-permissions to t or `advanced' made this >> work -- you can't really edit the permissions without that. > > That behavior not optimal and a bit confusing. Yeah, like a lot of stuff with dired and wdired, unfortunately. > I think we could make wdired explicitly check for and throw a > "user-error" in this case so that the editing command is not performed > (but only after the properties were attached). You mean in the wdired-allow-to-change-permissions nil case? Yes, definitely. From unknown Thu Aug 14 18:39:40 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 09 Oct 2022 11:24:07 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator