[Top][All Lists]

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

bug#15337: 24.3.50; [PATCH] cd to directory name with french accent fail

From: Thierry Volpiatto
Subject: bug#15337: 24.3.50; [PATCH] cd to directory name with french accent fail from term/ansi-term
Date: Fri, 13 Sep 2013 13:59:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Thierry Volpiatto <address@hidden> writes:

> Eli Zaretskii <address@hidden> writes:
>>> From: Thierry Volpiatto <address@hidden>
>>> Cc: address@hidden
>>> Date: Fri, 13 Sep 2013 07:21:44 +0200
>>> Eli Zaretskii <address@hidden> writes:
>>> > So please see if decoding the result of prog1 with
>>> > decode-coding-string, like you suggested to do in 'cd', but before
>>> > passing it to funcall, fixes the problem.  Something like this:
>>> >
>>> >      (funcall term-command-hook
>>> >               (decode-coding-string
>>> >                 (prog1 (substring str (1+ i) end)
>>> >                    (setq i (match-end 0)))
>>> >                 locale-coding-system))
>>> Yes it is working
>> Then please install.
> I can't, please do it.
>>> or just decoding 'string' in `term-command-hook' works too.
>> I considered that as well, but decided that doing it before
>> term-command-hook is called is better, since that hook might be
>> redefined by users of term.el (right?).  So it is better to pass the
>> hook an already decoded string, because Lisp code does not generally
>> expect to get unibyte strings, especially if they are file names.
> Ok.

BTW, `term-command-hook' is not really a hook and hardly customizable by
user, so probably the function with same name (confusing) should be
renamed and called directly (without funcall) and the var
`term-command-hook' removed.
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997 

reply via email to

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