From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thierry Volpiatto Newsgroups: gmane.emacs.bugs Subject: bug#13963: 24.3; eshell: "Text is read-only" and unresponsive eshell to kill-buffer, C-x C-c and C-x C-q Date: Sun, 17 Mar 2013 15:47:26 +0100 Organization: Emacs Helm Message-ID: <87ehfe6q2p.fsf@gmail.com> References: <87a9q5qfou.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1363532354 11869 80.91.229.3 (17 Mar 2013 14:59:14 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 17 Mar 2013 14:59:14 +0000 (UTC) To: 13963@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Mar 17 15:59:39 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UHF3e-0002Ia-EZ for geb-bug-gnu-emacs@m.gmane.org; Sun, 17 Mar 2013 15:59:34 +0100 Original-Received: from localhost ([::1]:45871 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UHF3H-0000GL-HZ for geb-bug-gnu-emacs@m.gmane.org; Sun, 17 Mar 2013 10:59:11 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:34198) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UHEyv-00081B-01 for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:59:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UHExq-0000FW-U9 for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:54:40 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:55929) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UHExq-0000FR-RG for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:53:34 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1UHEzG-0002Db-BN for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:55:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: Resent-From: Thierry Volpiatto Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 17 Mar 2013 14:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13963 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.13635321018520 (code B ref -1); Sun, 17 Mar 2013 14:55:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 17 Mar 2013 14:55:01 +0000 Original-Received: from localhost ([127.0.0.1]:60038 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UHEzE-0002DL-RO for submit@debbugs.gnu.org; Sun, 17 Mar 2013 10:55:01 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:50658) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UHEzC-0002Cw-MZ for submit@debbugs.gnu.org; Sun, 17 Mar 2013 10:54:59 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UHEwd-0008M2-9s for submit@debbugs.gnu.org; Sun, 17 Mar 2013 10:53:25 -0400 Original-Received: from lists.gnu.org ([208.118.235.17]:54979) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UHEwd-0008Lu-64 for submit@debbugs.gnu.org; Sun, 17 Mar 2013 10:52:19 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:60681) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UHEtA-0005v8-8Z for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:52:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UHEs6-0006ly-66 for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:48:44 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:45417) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UHEs5-0006lk-V6 for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 10:47:38 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1UHEsQ-0000cq-G3 for bug-gnu-emacs@gnu.org; Sun, 17 Mar 2013 15:47:58 +0100 Original-Received: from lbe83-2-78-243-104-167.fbx.proxad.net ([78.243.104.167]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 17 Mar 2013 15:47:58 +0100 Original-Received: from thierry.volpiatto by lbe83-2-78-243-104-167.fbx.proxad.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 17 Mar 2013 15:47:58 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 54 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lbe83-2-78-243-104-167.fbx.proxad.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) Cancel-Lock: sha1:EtUDCBzUmh2BV891LxmVnP3E89s= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: -4.9 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-Spam-Score: -4.9 (----) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:72632 Archived-At: Thierry Volpiatto writes: > joe M writes: > >> Reproducing the bug: >> >> 1. Type something right after the '$' in the prompt without a space. For >> example, '$pwd' instead of '$ pwd'. That causes the "Text is read-only" >> message. >> 2. Cannot close out of eshell or emacs when that message appears >> 3. The only way to close out of eshell/emacs is: >> joe9: M-: (let ((inhibit-read-only t)) (kill-this-buffer)) in the >> eshell buffer. >> To recover after the bug triggers, that is, not to solve the bug .. >> joe9: you can also C-x C-e after forms such as taylanub's if you get >> into a situation where M-: doesn't function [14:59] >> >> > > The problem I think is that the eshell prompt is read-only but this > doesn't forbid user to write in this zone and because the prompt have > also rear-nonsticky property, the new character entered are made > read-only and eshell when it try to delete this characters return "text > read only". > Didn't look deeper where this happen though. I resend, it seems the sended patch never arrive here ? diff --git a/lisp/eshell/em-prompt.el b/lisp/eshell/em-prompt.el index c1c4d47..bb6f563 100644 --- a/lisp/eshell/em-prompt.el +++ b/lisp/eshell/em-prompt.el @@ -119,11 +119,12 @@ arriving, or after." (set-marker eshell-last-output-end (point)) (let ((prompt (funcall eshell-prompt-function))) (and eshell-highlight-prompt - (add-text-properties 0 (length prompt) - '(read-only t - face eshell-prompt - rear-nonsticky (face read-only)) - prompt)) + (add-text-properties 0 + ;; Assume `eshell-prompt-function' + ;; add a space at end of prompt. + (1- (length prompt)) + '(read-only t face eshell-prompt) + prompt)) (eshell-interactive-print prompt))) (run-hooks 'eshell-after-prompt-hook)) -- Thierry Get my Gnupg key: gpg --keyserver pgp.mit.edu --recv-keys 59F29997