GNU bug report logs -
#37228
[PATCH] tramp: dired for files which name contains spaces
Previous Next
Reported by: Koichi Arakawa <arakawa <at> pp.iij4u.or.jp>
Date: Fri, 30 Aug 2019 05:29:01 UTC
Severity: normal
Tags: patch
Fixed in version 27.1
Done: Michael Albinus <michael.albinus <at> gmx.de>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hi,
It seems for me that the current version of tramp does not handle
dired properly for files which name contains spaces.
How about using the '-0' option of xargs?
Regards,
Koichi Arakawa
--- tramp-sh.el.~1~ 2019-08-28 07:24:07.781000000 +0900
+++ tramp-sh.el 2019-08-30 13:59:34.747676700 +0900
@@ -1762,8 +1762,8 @@
;; Apostrophes in the stat output are masked as
;; `tramp-stat-marker', in order to make a proper shell escape
;; of them in file names.
- "cd %s && echo \"(\"; (%s %s -a | "
- "xargs %s -c "
+ "cd %s && echo \"(\"; (%s %s -a | tr '\\n' '\\0' | "
+ "xargs -0 %s -c "
"'(%s%%n%s (%s%%N%s) %%h %s %s %%X %%Y %%Z %%s %s%%A%s t %%i -1)' "
"-- 2>/dev/null | sed -e 's/\"/\\\\\"/g' -e 's/%s/\"/g'); echo \")\""))
(tramp-shell-quote-argument localname)
This bug report was last modified 5 years and 258 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.