GNU bug report logs - #11194
24.0.95; sudo rm doesn't work with absolute directory paths on the file system

Previous Next

Package: emacs;

Reported by: Cray Elliott <mp2e <at> archlinux.us>

Date: Sat, 7 Apr 2012 18:15:02 UTC

Severity: normal

Found in version 24.0.95

Done: Chong Yidong <cyd <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Michael Albinus <michael.albinus <at> gmx.de>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Cray Elliott <mp2e <at> archlinux.us>, 11194 <at> debbugs.gnu.org
Subject: bug#11194: 24.0.95; sudo rm doesn't work with absolute directory paths on the file system
Date: Tue, 10 Apr 2012 09:07:21 +0200
Stefan Monnier <monnier <at> iro.umontreal.ca> writes:

>>> While using Tramp might make sense, I think that "sudo rm -rf /foo/bar"
>>> is a perfectly valid command and wonder why it wouldn't work correctly.
>> In eshell, `sudo' is an built-in for `eshell/sudo':
>
> That does not in itself explain why it doesn't do the right thing: the
> intention seems fairly clear.

Sure.

The problem is `rm', which is another built-in. Built-ins are not aware
of being called in a `su(do)?' context.

Sounds like a new feature in eshell. Do we want it? Do we know, that
there are no unwanted side effects, if (local) "/foo/bar" is handled as
(remote) "/su(do)?::/foo/bar" for *all* built-ins, when being called
from `eshell/su(do)?'?

>         Stefan

Best regards, Michael.




This bug report was last modified 13 years and 85 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.