unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#2261: Dired with long ls switches
@ 2009-02-10  6:06 ` David Brown
  2009-02-11 14:55   ` bug#2261: marked as done (Dired with long ls switches) Emacs bug Tracking System
  0 siblings, 1 reply; 2+ messages in thread
From: David Brown @ 2009-02-10  6:06 UTC (permalink / raw)
  To: bug-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 2869 bytes --]

I have "GNU Emacs 22.2.1 (i486-pc-linux-gnu, GTK+ Version 2.14.1) of
2008-09-05 on vernadsky, modified by Ubuntu," known as emacs22-gtk by my
distro.

I like --group-directories-first as an ls switch:  (setq
dired-listing-switches "-al --group-directories-first")

In dired, when I do a file operation such as R-rename or M-chmod, the system
file operation works, but the dired buffer does not update properly, giving:
Listing directory failed but `access-file' worked

This is because a character "d" is being appended to dired-actual-switches
about 50 lines into dired-add-entry:
  (dired-insert-directory directory
     (concat dired-actual-switches "d")
     (list filename)))

Just concatenating "d" assumes short switches.  For example "-ald" works
fine.  But "-al --group-directories-firstd" fails.

I fixed my installation by putting " -d" instead of "d".  This seems to work
just fine for files and directories

Here is the debugger backtrace:

Debugger entered--Lisp error: (error "Listing directory failed but
`access-file' worked")
  signal(error ("Listing directory failed but `access-file' worked"))
  error("Listing directory failed but `access-file' worked")
  insert-directory("foobar" "--dired -al --group-directories-firstd" nil
nil)
  dired-insert-directory("/home/dmb/bin/" "-al --group-directories-firstd"
("foobar"))
  (let ((default-directory directory)) (dired-insert-directory directory
(concat dired-actual-switches "d") (list filename)))
  (let (buffer-read-only opoint) (beginning-of-line) (setq opoint (point))
(let (...) (dired-insert-directory directory ... ...)) (goto-char opoint)
(when marker-char (let ... ...)) (goto-char opoint) (let (...) (if ... ...
...)) (forward-line -1) (if dired-after-readin-hook (save-excursion ...))
(dired-move-to-filename))
  (catch (quote not-found) (if (string= directory cur-dir) (progn ... ...
...) (if ... ... ...)) (let (buffer-read-only opoint) (beginning-of-line)
(setq opoint ...) (let ... ... ...) (goto-char opoint) (when marker-char
...) (goto-char opoint) (let ... ...) (forward-line -1) (if
dired-after-readin-hook ...) (dired-move-to-filename)) nil)
  (setq filename (if relative (file-relative-name filename directory)
(file-name-nondirectory filename)) reason (catch (quote not-found) (if ...
... ...) (let ... ... ... ... ... ... ... ... ... ... ...) nil))
  (let* ((opoint ...) (cur-dir ...) (orig-file-name filename) (directory
...) reason) (setq filename (if relative ... ...) reason (catch ... ... ...
nil)) (if reason (goto-char opoint)) (not reason))
  dired-add-entry("/home/dmb/bin/foobar" nil)
  apply(dired-add-entry ("/home/dmb/bin/foobar" nil))
  dired-fun-in-all-buffers("/home/dmb/bin/" "foobar" dired-add-entry
"/home/dmb/bin/foobar" nil)
  dired-add-file("/home/dmb/bin/foobar" nil)
  byte-code("\b \n\v#ˆ\fƒ\x0e



[-- Attachment #2: Type: text/html, Size: 5557 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#2261: marked as done (Dired with long ls switches)
  2009-02-10  6:06 ` bug#2261: Dired with long ls switches David Brown
@ 2009-02-11 14:55   ` Emacs bug Tracking System
  0 siblings, 0 replies; 2+ messages in thread
From: Emacs bug Tracking System @ 2009-02-11 14:55 UTC (permalink / raw)
  To: Chong Yidong

[-- Attachment #1: Type: text/plain, Size: 840 bytes --]


Your message dated Wed, 11 Feb 2009 09:47:52 -0500
with message-id <87wsbx1147.fsf@cyd.mit.edu>
and subject line Re: Dired with long ls switches
has caused the Emacs bug report #2261,
regarding Dired with long ls switches
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@emacsbugs.donarmstrong.com
immediately.)


-- 
2261: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=2261
Emacs Bug Tracking System
Contact owner@emacsbugs.donarmstrong.com with problems

[-- Attachment #2: Type: message/rfc822, Size: 11297 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 2869 bytes --]

I have "GNU Emacs 22.2.1 (i486-pc-linux-gnu, GTK+ Version 2.14.1) of
2008-09-05 on vernadsky, modified by Ubuntu," known as emacs22-gtk by my
distro.

I like --group-directories-first as an ls switch:  (setq
dired-listing-switches "-al --group-directories-first")

In dired, when I do a file operation such as R-rename or M-chmod, the system
file operation works, but the dired buffer does not update properly, giving:
Listing directory failed but `access-file' worked

This is because a character "d" is being appended to dired-actual-switches
about 50 lines into dired-add-entry:
  (dired-insert-directory directory
     (concat dired-actual-switches "d")
     (list filename)))

Just concatenating "d" assumes short switches.  For example "-ald" works
fine.  But "-al --group-directories-firstd" fails.

I fixed my installation by putting " -d" instead of "d".  This seems to work
just fine for files and directories

Here is the debugger backtrace:

Debugger entered--Lisp error: (error "Listing directory failed but
`access-file' worked")
  signal(error ("Listing directory failed but `access-file' worked"))
  error("Listing directory failed but `access-file' worked")
  insert-directory("foobar" "--dired -al --group-directories-firstd" nil
nil)
  dired-insert-directory("/home/dmb/bin/" "-al --group-directories-firstd"
("foobar"))
  (let ((default-directory directory)) (dired-insert-directory directory
(concat dired-actual-switches "d") (list filename)))
  (let (buffer-read-only opoint) (beginning-of-line) (setq opoint (point))
(let (...) (dired-insert-directory directory ... ...)) (goto-char opoint)
(when marker-char (let ... ...)) (goto-char opoint) (let (...) (if ... ...
...)) (forward-line -1) (if dired-after-readin-hook (save-excursion ...))
(dired-move-to-filename))
  (catch (quote not-found) (if (string= directory cur-dir) (progn ... ...
...) (if ... ... ...)) (let (buffer-read-only opoint) (beginning-of-line)
(setq opoint ...) (let ... ... ...) (goto-char opoint) (when marker-char
...) (goto-char opoint) (let ... ...) (forward-line -1) (if
dired-after-readin-hook ...) (dired-move-to-filename)) nil)
  (setq filename (if relative (file-relative-name filename directory)
(file-name-nondirectory filename)) reason (catch (quote not-found) (if ...
... ...) (let ... ... ... ... ... ... ... ... ... ... ...) nil))
  (let* ((opoint ...) (cur-dir ...) (orig-file-name filename) (directory
...) reason) (setq filename (if relative ... ...) reason (catch ... ... ...
nil)) (if reason (goto-char opoint)) (not reason))
  dired-add-entry("/home/dmb/bin/foobar" nil)
  apply(dired-add-entry ("/home/dmb/bin/foobar" nil))
  dired-fun-in-all-buffers("/home/dmb/bin/" "foobar" dired-add-entry
"/home/dmb/bin/foobar" nil)
  dired-add-file("/home/dmb/bin/foobar" nil)
  byte-code("\b \n\v#ˆ\fƒ\x0e



[-- Attachment #2.1.2: Type: text/html, Size: 5557 bytes --]

[-- Attachment #3: Type: message/rfc822, Size: 1438 bytes --]

From: Chong Yidong <cyd@stupidchicken.com>
To: "David Brown" <dmbrown@icubed.com>
Cc: 2261-done@emacsbugs.donarmstrong.com
Subject: Re: Dired with long ls switches
Date: Wed, 11 Feb 2009 09:47:52 -0500
Message-ID: <87wsbx1147.fsf@cyd.mit.edu>

> In dired, when I do a file operation such as R-rename or M-chmod, the
> system file operation works, but the dired buffer does not update
> properly, giving: Listing directory failed but `access-file' worked
>
> This is because a character "d" is being appended to
> dired-actual-switches about 50 lines into dired-add-entry:

Thanks for spotting and analyzing this bug.  I've checked a fix into
CVS.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-02-11 14:55 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <87wsbx1147.fsf@cyd.mit.edu>
2009-02-10  6:06 ` bug#2261: Dired with long ls switches David Brown
2009-02-11 14:55   ` bug#2261: marked as done (Dired with long ls switches) Emacs bug Tracking System

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).