emacs-devel
[Top][All Lists]
Advanced

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

address@hidden: a bug of read-passwd]


From: Richard Stallman
Subject: address@hidden: a bug of read-passwd]
Date: Sat, 15 Jul 2006 13:16:12 -0400

I wonder if this is a consequence of the new sit-for code.
Would someone please investigate, then ack this message?

------- Start of forwarded message -------
DKIM-Signature: a=rsa-sha1; c=relaxed/simple; d=iij.ad.jp; s=omgo0;
        t=1152939160; bh=3mhCZUjonim4IiCzzKXwlGTyEu8=; h=Received:Received:
        Date:Message-Id:To:Subject:From:X-Mailer:Mime-Version:Content-Type:
        Content-Transfer-Encoding; b=NYBNO/qQoOsroMzwkHp6O7uqWNe+Vhjlofn0m1
        CrNZrspQa6+N/HXDG3p5UepfAwt+dX1CtHd3Dxc8zuWmqePgbUq2wdLE+OFSdUW6F2W
        qN4QWThGMEPiM599VkzY8FDelF5emurJNv1Yqvyjwq1izfE39MKa6LLnB6ADVMVK4A=
Date: Sat, 15 Jul 2006 13:49:49 +0900 (JST)
To: address@hidden
From: Kazu Yamamoto (=?iso-2022-jp?B?GyRCOzNLXE9CSScbKEI=?=) <address@hidden>
Mime-Version: 1.0
Content-Type: Text/Plain; charset=us-ascii
Subject: a bug of read-passwd
X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=failed 
        version=3.0.4

Hello,

Recent changes of Emacs introduces a new bug to read-passwd.  If
read-passwd is called a filter of an asynchronous process and the
parent code executes sit-for, the cursor goes away from the minibuffer
and we cannot input our password.

The following code can reproduce this:

(defvar my-check nil)

(defun my-filter (process string)
  (set-buffer (process-buffer process))
  (read-passwd "Password: ")
  (setq my-check nil))

(let ((pro (start-process "*sh*" (current-buffer) "/bin/sh")))
  (setq my-check t)
  (set-process-filter pro 'my-filter)
  (while my-check
    (sit-for 0.1)
    (discard-input)))

The parent code calls sit-for to synchronize with its child process.
The code above is essence of a program which I use everyday.

This code works Emacs, at least, before Jun 31 2006.

- --Kazu Yamamoto


_______________________________________________
Emacs-devel mailing list
address@hidden
http://lists.gnu.org/mailman/listinfo/emacs-devel
------- End of forwarded message -------




reply via email to

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