[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug] read-passwd of CVS Emacs
From: |
David Kastrup |
Subject: |
Re: [bug] read-passwd of CVS Emacs |
Date: |
Wed, 24 May 2006 18:35:05 +0200 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
Kevin Rodgers <address@hidden> writes:
> Kazu Yamamoto (山本和彦) wrote:
>> If the CONFIRM argument is specified to read-passwd of CVS Emacs, it
>> causes an error after a user type a first password.
>>
>> (read-passwd "password: " t)
>
> The error is "Attempt to modify read-only object" and is somehow caused
> by a string indexing bug. Here's a patch:
>
> 2006-05-24 Kevin Rodgers <address@hidden>
>
> * subr.el (read-passwd): Fix END argument to add-text-properties.
>
>
> *** lisp/subr.el~ 2006-04-22 06:42:24.750000000 -0600
> --- lisp/subr.el 2006-05-24 09:56:54.555250000 -0600
> ***************
> *** 1542,1548 ****
> (echo-keystrokes 0)
> (cursor-in-echo-area t)
> (message-log-max nil))
> ! (add-text-properties 0 (length prompt)
> minibuffer-prompt-properties prompt)
> (while (progn (message "%s%s"
> prompt
> --- 1542,1548 ----
> (echo-keystrokes 0)
> (cursor-in-echo-area t)
> (message-log-max nil))
> ! (add-text-properties 0 (1- (length prompt))
> minibuffer-prompt-properties prompt)
> (while (progn (message "%s%s"
> prompt
Looks like causing trouble when the prompt is an empty string. And it
looks like it would leave the properties off the last character of the
prompt. Correct?
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum