From unknown Tue Jun 17 20:19:06 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#11919 <11919@debbugs.gnu.org> To: bug#11919 <11919@debbugs.gnu.org> Subject: Status: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present Reply-To: bug#11919 <11919@debbugs.gnu.org> Date: Wed, 18 Jun 2025 03:19:06 +0000 retitle 11919 24.1; term-emulate-term does not process bash's Ctrl-Z signal= of directory name when an AnSi message is present reassign 11919 emacs submitter 11919 Michael Hoffman severity 11919 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Jul 11 20:51:15 2012 Received: (at submit) by debbugs.gnu.org; 12 Jul 2012 00:51:15 +0000 Received: from localhost ([127.0.0.1]:34252 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Sp7cg-000730-BC for submit@debbugs.gnu.org; Wed, 11 Jul 2012 20:51:14 -0400 Received: from eggs.gnu.org ([208.118.235.92]:56637) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Sp7cd-00072r-SF for submit@debbugs.gnu.org; Wed, 11 Jul 2012 20:51:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Sp7XJ-00023e-Gp for submit@debbugs.gnu.org; Wed, 11 Jul 2012 20:45:42 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:35022) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Sp7XJ-00023a-BZ for submit@debbugs.gnu.org; Wed, 11 Jul 2012 20:45:41 -0400 Received: from eggs.gnu.org ([208.118.235.92]:33417) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Sp7XH-0001RK-Qb for bug-gnu-emacs@gnu.org; Wed, 11 Jul 2012 20:45:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Sp7XG-00020v-16 for bug-gnu-emacs@gnu.org; Wed, 11 Jul 2012 20:45:39 -0400 Received: from mail-ob0-f169.google.com ([209.85.214.169]:63616) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Sp7XF-00020o-RV for bug-gnu-emacs@gnu.org; Wed, 11 Jul 2012 20:45:37 -0400 Received: by obhx4 with SMTP id x4so2816920obh.0 for ; Wed, 11 Jul 2012 17:45:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:from:date:x-google-sender-auth:message-id :subject:to:content-type; bh=S4WwU2MSjwG/z6jG8xH8Ksh/SH27wnUDfpqidRj4IxI=; b=Aq/OD2CAe9JmD0jjRGsqmIrsRk6B779OXkyvgwKJa4OicbeegcLu194NbfT4mj0uBH /jrcpFjqAivVL1ou7lV+UAdapULeJ2vpiN1uSctP11WrNEBOLtw2OF7AkUrvZQPd/bM6 etP2O/M6AHmlC//x39Lemqp2t4E5nN1V3cZMwjnFK/9uMH2vLIEwvB1btygCzb4GF7CY 6rcW/YiljAEsxc9pg5CwTxHAyGO0+Q1TKpUjQPeDfbsu4kchsyZuDG5dq+BVcZiRQUcG QXeRtdlqUQIWtKfUhaCyYUaiLiqxCWLYoSOkJdlgy7FC46174H+g0C4G2Bo8oW474fLp i3Tg== Received: by 10.182.146.84 with SMTP id ta20mr5521634obb.19.1342053937244; Wed, 11 Jul 2012 17:45:37 -0700 (PDT) MIME-Version: 1.0 Received: by 10.76.167.161 with HTTP; Wed, 11 Jul 2012 17:45:16 -0700 (PDT) From: Michael Hoffman Date: Wed, 11 Jul 2012 17:45:16 -0700 X-Google-Sender-Auth: o81Jkx5KvRnu2Y53MJRPrnkO-7I Message-ID: Subject: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset=ISO-8859-1 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 (newer, 3) X-Received-From: 208.118.235.17 X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) This bug report will be sent to the Bug-GNU-Emacs mailing list and the GNU bug tracker at debbugs.gnu.org. Please check that the From: line contains a valid email address. After a delay of up to one day, you should receive an acknowledgement at that address. Please write in English if possible, as the Emacs maintainers usually do not have translators for other languages. Please describe exactly what actions triggered the bug, and the precise symptoms of the bug. If you can, give a recipe starting from `emacs -Q': I have GNU bash, version 4.1.2(1). When I do this: 1) emacs -Q 2) M-x ansi-term RET /bin/bash RET 3) PS1='\033AnSiTu x\012$ ' RET >From then on, every prompt will be preceded by a Ctrl-Z character and the working directory. This is because recent versions of bash try to figure out whether they are running under emacs, and if they are, output Ctrl-Z and the working directory before the PS1 prompt. term-emulate-terminal normally eliminates such garbage, but not when it has also processed an AnSi message. The elimination only happens when the following conditions are true: (and (eq char ?\032) (not handled-ansi-message)) Suggested fix: eliminate the "(not handled-ansi-message)" form. If Emacs crashed, and you have the Emacs process in the gdb debugger, please include the output from the following gdb commands: `bt full' and `xbacktrace'. For information about debugging Emacs, please read the file /net/gs/vol3/software/modules-sw/emacs/24.1/Linux/RHEL6/x86_64/share/emacs/24.1/etc/DEBUG. In GNU Emacs 24.1.2 (x86_64-unknown-linux-gnu, GTK+ Version 2.18.9) of 2012-06-21 on rhel6-x64.grid.gs.washington.edu Windowing system distributor `Red Hat, Inc.', version 11.0.11004000 Configured using: `configure '--without-gif' '--with-x' '--with-x-toolkit=gtk' '--prefix=/net/gs/vol3/software/modules-sw/emacs/24.1/Linux/RHEL6/x86_64' 'LDFLAGS=-L/net/gs/vol3/software/modules-sw/boost/1.45.0/Linux/RHEL6/x86_64/lib/ -L/net/gs/vol3/software/modules-sw/R/2.9.0/Linux/RHEL6/x86_64/lib/' 'CPPFLAGS=-I/net/gs/vol3/software/modules-sw/boost/1.45.0/Linux/RHEL6/x86_64/include/ -I/net/gs/vol3/software/modules-sw/R/2.9.0/Linux/RHEL6/x86_64/include/'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: en_US value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US.UTF-8 value of $XMODIFIERS: nil locale-coding-system: iso-latin-1-unix default enable-multibyte-characters: t Major mode: Lisp Interaction Minor modes in effect: tooltip-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent input: M-x r e p o r t - b Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. goto-history-element: Beginning of history; no preceding item goto-history-element: End of history; no default available Load-path shadows: None found. Features: (shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml easymenu mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail regexp-opt rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils time-date tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image fringe lisp-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces cus-face files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process dynamic-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs) From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 23 13:03:46 2017 Received: (at submit) by debbugs.gnu.org; 23 Jan 2017 18:03:46 +0000 Received: from localhost ([127.0.0.1]:39368 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cViy1-0004kz-Pc for submit@debbugs.gnu.org; Mon, 23 Jan 2017 13:03:46 -0500 Received: from eggs.gnu.org ([208.118.235.92]:46767) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVip0-0004Vj-8P for submit@debbugs.gnu.org; Mon, 23 Jan 2017 12:54:27 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cViot-0005Pl-TZ for submit@debbugs.gnu.org; Mon, 23 Jan 2017 12:54:21 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:50856) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cViot-0005Pe-QL for submit@debbugs.gnu.org; Mon, 23 Jan 2017 12:54:19 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37734) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cVios-0003Y1-Gx for bug-gnu-emacs@gnu.org; Mon, 23 Jan 2017 12:54:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cVion-0005No-N0 for bug-gnu-emacs@gnu.org; Mon, 23 Jan 2017 12:54:18 -0500 Received: from sneak2.sneakemail.com ([64.46.156.55]:34159) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cVion-0005Nd-Hj for bug-gnu-emacs@gnu.org; Mon, 23 Jan 2017 12:54:13 -0500 Received: from 128.100.132.181 by sneak2.sneakemail.com with SMTP; 23 Jan 2017 17:58:03 -0000 Received: (sneakemail censored 26119-1485194282-859484 #3); 23 Jan 2017 17:58:03 -0000 Received: (sneakemail censored 26119-1485194282-859484 #2); 23 Jan 2017 17:58:03 -0000 Received: (sneakemail censored 26119-1485194282-859484 #1); 23 Jan 2017 17:58:03 -0000 From: "Michael Hoffman" Subject: Re: bug#11919: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present References: To: bug-gnu-emacs@gnu.org Message-ID: <26119-1485194282-859484@sneakemail.com> Date: Mon, 23 Jan 2017 12:54:10 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Mailer: Perl5 Mail::Internet v X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.4 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Mon, 23 Jan 2017 13:03:43 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.4 (----) On 07/11/2012 08:45 PM, Michael Hoffman wrote: > 1) emacs -Q > 2) M-x ansi-term RET /bin/bash RET > 3) PS1='\033AnSiTu x\012$ ' RET > > From then on, every prompt will be preceded by a Ctrl-Z character and > the working directory. This is because recent versions of bash > try to figure out whether they are running under emacs, and if they > are, output Ctrl-Z and the working directory before the PS1 prompt. > term-emulate-terminal normally eliminates such garbage, but not when > it has also processed an AnSi message. The elimination only happens > when the following conditions are true: > > (and (eq char ?\032) > (not handled-ansi-message)) > > Suggested fix: eliminate the "(not handled-ansi-message)" form. I have located the original commit that added the `handled-ansi-message` behavior: https://github.com/emacs-mirror/emacs/commit/59be5828de98814b8aa32718bf2b6196db085db1 Eli Zaretskii added it to "Let term-handle-ansi-terminal-messages override what Bash says about its current directory." In order to keep this behavior but not print garbage to the buffer: I would suggest that perhaps the call to `term-command-hook` is what should be conditioned on `(not handled-ansi-message)` and not the rest of the code in this branch which seems to remove the garbage. Michael Hoffman From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 23 13:19:15 2017 Received: (at 11919) by debbugs.gnu.org; 23 Jan 2017 18:19:15 +0000 Received: from localhost ([127.0.0.1]:39373 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVjD0-00057S-8P for submit@debbugs.gnu.org; Mon, 23 Jan 2017 13:19:15 -0500 Received: from eggs.gnu.org ([208.118.235.92]:52939) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVjCy-00057D-5m for 11919@debbugs.gnu.org; Mon, 23 Jan 2017 13:19:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cVjCo-000662-PF for 11919@debbugs.gnu.org; Mon, 23 Jan 2017 13:19:06 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-3.2 required=5.0 tests=BAYES_20,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:57913) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cVjCo-00065y-Li; Mon, 23 Jan 2017 13:19:02 -0500 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4741 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cVjCn-00058O-Ex; Mon, 23 Jan 2017 13:19:02 -0500 Date: Mon, 23 Jan 2017 20:18:51 +0200 Message-Id: <83ziih3aic.fsf@gnu.org> From: Eli Zaretskii To: "Michael Hoffman" In-reply-to: <26119-1485194282-859484@sneakemail.com> (gmane3-hoffman@snkmail.com) Subject: Re: bug#11919: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present References: <26119-1485194282-859484@sneakemail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -8.2 (--------) X-Debbugs-Envelope-To: 11919 Cc: 11919@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -8.2 (--------) > From: "Michael Hoffman" > Date: Mon, 23 Jan 2017 12:54:10 -0500 > > I have located the original commit that added the `handled-ansi-message` > behavior: > https://github.com/emacs-mirror/emacs/commit/59be5828de98814b8aa32718bf2b6196db085db1 > > Eli Zaretskii added it to "Let term-handle-ansi-terminal-messages > override what Bash says about its current directory." I was just committing someone else's patch in that case. See these messages in the archives for the reason why that change was done: https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-11/msg00020.html https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-11/msg00103.html https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-12/msg00089.html If you can propose changes that solve this issue without re-introducing that one, please do. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 23 13:30:46 2017 Received: (at 11919) by debbugs.gnu.org; 23 Jan 2017 18:30:46 +0000 Received: from localhost ([127.0.0.1]:39377 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVjOA-0005PM-C7 for submit@debbugs.gnu.org; Mon, 23 Jan 2017 13:30:46 -0500 Received: from eggs.gnu.org ([208.118.235.92]:54948) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVjO8-0005PA-UD for 11919@debbugs.gnu.org; Mon, 23 Jan 2017 13:30:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cVjNz-0000R0-9G for 11919@debbugs.gnu.org; Mon, 23 Jan 2017 13:30:39 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_05,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:57999) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cVjNz-0000Qw-5n; Mon, 23 Jan 2017 13:30:35 -0500 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4745 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cVjNy-0003Cn-0N; Mon, 23 Jan 2017 13:30:34 -0500 Date: Mon, 23 Jan 2017 20:30:23 +0200 Message-Id: <83y3y139z4.fsf@gnu.org> From: Eli Zaretskii To: gmane3-hoffman@snkmail.com In-reply-to: <83ziih3aic.fsf@gnu.org> (message from Eli Zaretskii on Mon, 23 Jan 2017 20:18:51 +0200) Subject: Re: bug#11919: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present References: <26119-1485194282-859484@sneakemail.com> <83ziih3aic.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -8.2 (--------) X-Debbugs-Envelope-To: 11919 Cc: 11919@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -8.2 (--------) > Date: Mon, 23 Jan 2017 20:18:51 +0200 > From: Eli Zaretskii > Cc: 11919@debbugs.gnu.org > > > From: "Michael Hoffman" > > Date: Mon, 23 Jan 2017 12:54:10 -0500 > > > > I have located the original commit that added the `handled-ansi-message` > > behavior: > > https://github.com/emacs-mirror/emacs/commit/59be5828de98814b8aa32718bf2b6196db085db1 > > > > Eli Zaretskii added it to "Let term-handle-ansi-terminal-messages > > override what Bash says about its current directory." > > I was just committing someone else's patch in that case. Btw, in the ChangeLog file this change is attributed correctly: 2005-12-16 Mark Plaksin (tiny change) * term.el (term-emulate-terminal): Let term-handle-ansi-terminal-messages override what Bash says about its current directory. From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 23 14:24:57 2017 Received: (at 11919) by debbugs.gnu.org; 23 Jan 2017 19:24:57 +0000 Received: from localhost ([127.0.0.1]:39413 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVkEb-0006lK-FI for submit@debbugs.gnu.org; Mon, 23 Jan 2017 14:24:57 -0500 Received: from mail-wm0-f46.google.com ([74.125.82.46]:34959) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cVkEZ-0006l5-31 for 11919@debbugs.gnu.org; Mon, 23 Jan 2017 14:24:55 -0500 Received: by mail-wm0-f46.google.com with SMTP id r126so148829811wmr.0 for <11919@debbugs.gnu.org>; Mon, 23 Jan 2017 11:24:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=ffpcrwz64ZKWG2UEBlbRjzv/fK2mMgWVVhKjnlwpRo4=; b=pD/3GpB7D4q+0m/9E3VwTi6md5fnmJLoiGHzBQJkzWTGqAhbPy/vmAGZ1F5J3oRPig XO8TePRX2WIAXM9+WM0nYicXC6sczjDdgKZnV1pXuonXpZZutYGbX0FOKbjAQtBQwzbH 5vLN/a64tglqonswvA72c9WyXA91hkKAoap8EXQg/eYHi6YO68Wu/dgh4py0G73s1zsx nPFnQup4pZOy7jmwaIu4VddTJGoybgh2wp+nOh+VzHcx8x6dDIL8Ht7colgGrIcI54Uo fgHh4RVYRaKH/kbn/7IHxWt78/3BL11PoaW1+tZzP4H3GsECwtWyYXZq60XCD7iEtKpw RpNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=ffpcrwz64ZKWG2UEBlbRjzv/fK2mMgWVVhKjnlwpRo4=; b=GAGA/kj0L8YMLXTFBDp7e+t9qO6ulC+NuoNfJDf8SETZpqUYCumGnI05/ixlKR8LOR Flj1kUq25RY9CflXq/AfC7kX7qGxhWfBWcmRLnhE8aimg6h0IR0/gjy7cQGjp5FSZD7K WsBxSLKUsauqgflQ093IXecMKQr1UidbuNZj1zCalDxKDqx5wNR9hAPhG/z5lgCVr1ew Eqw7y4DJHRUoam7dSqI4m54Mud3oa7OK/bVyGjn9jMY7qRSLtVTyo/GYPLXyzrMcs5S6 FzKz20xNdDQZb522VnKwi7VaJylwp3T1jZjpxLe4PyYKy9KWYc6+xT2vVSghcWqx/pZo U/gw== X-Gm-Message-State: AIkVDXLxLxtF4bYWOBecIRFWhsL5yF9/A8720SsIZVdVdVSFHQiZQJPyGKJVMs2PNDQOTRVjUvqoySENpbUs8Q== X-Received: by 10.28.96.130 with SMTP id u124mr16412182wmb.81.1485199489212; Mon, 23 Jan 2017 11:24:49 -0800 (PST) MIME-Version: 1.0 Received: by 10.195.12.225 with HTTP; Mon, 23 Jan 2017 11:24:28 -0800 (PST) In-Reply-To: <83ziih3aic.fsf@gnu.org> References: <26119-1485194282-859484@sneakemail.com> <83ziih3aic.fsf@gnu.org> From: Michael Hoffman Date: Mon, 23 Jan 2017 14:24:28 -0500 X-Google-Sender-Auth: wKGPi-IMcA_WYtwCVQShF3_Cgro Message-ID: Subject: Re: bug#11919: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present To: "Eli Zaretskii eliz-at-gnu.org |gmane3-hoffman|" <0wdp3p2xrt@sneakemail.com> Content-Type: multipart/alternative; boundary=001a1148f03af9b2840546c7f326 X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 11919 Cc: 11919@debbugs.gnu.org, Michael Hoffman X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.5 (/) --001a1148f03af9b2840546c7f326 Content-Type: text/plain; charset=UTF-8 On Mon, Jan 23, 2017 at 1:18 PM, Eli Zaretskii eliz-at-gnu.org |gmane3-hoffman| <0wdp3p2xrt@sneakemail.com> wrote: > > From: "Michael Hoffman" > > Date: Mon, 23 Jan 2017 12:54:10 -0500 > > > > I have located the original commit that added the `handled-ansi-message` > > behavior: > > https://github.com/emacs-mirror/emacs/commit/59be5828de98814 > b8aa32718bf2b6196db085db1 > > > > Eli Zaretskii added it to "Let term-handle-ansi-terminal-messages > > override what Bash says about its current directory." > > I was just committing someone else's patch in that case. > Please accept my apologies. > See these messages in the archives for the reason why that change was > done: > > https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-11 > /msg00020.html > https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-11 > /msg00103.html > https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-12 > /msg00089.html > > If you can propose changes that solve this issue without > re-introducing that one, please do. > The below patch eliminates the garbage printing while maintaining the behavior added in 2005 of having `handled-ansi-message` preventing any updates to `default-directory` based on a \032 escape. mhoffman@mhoffman2 ~/share/emacs/25.1/lisp $ diff -u <(zcat term.el.gz) term.el --- /dev/fd/63 2017-01-23 14:13:55.948963291 -0500 +++ term.el 2017-01-23 14:11:43.903830242 -0500 @@ -2869,15 +2869,16 @@ ((eq char ?\017)) ; Shift In - ignored ((eq char ?\^G) ;; (terminfo: bel) (beep t)) - ((and (eq char ?\032) - (not handled-ansi-message)) + ((eq char ?\032) (let ((end (string-match "\r?$" str i))) (if end - (funcall term-command-hook - (decode-coding-string - (prog1 (substring str (1+ i) end) - (setq i (match-end 0))) - locale-coding-system)) + (progn + (unless handled-ansi-message + (funcall term-command-hook + (decode-coding-string + (substring str (1+ i) end) + locale-coding-system))) + (setq i (match-end 0))) (setq term-terminal-parameter (substring str i)) (setq term-terminal-state 4) (setq i str-length)))) ==== ChangeLog: 2017-01-23 Michael Hoffman * term.el (term-emulate-terminal): fix bug#11919: do not display ?\032 escape codes even when `handled-ansi-message` is true --001a1148f03af9b2840546c7f326 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: base64 PGRpdiBkaXI9Imx0ciI+PGRpdiBjbGFzcz0iZ21haWxfZXh0cmEiPjxkaXYgY2xhc3M9ImdtYWls X3F1b3RlIj5PbiBNb24sIEphbiAyMywgMjAxNyBhdCAxOjE4IFBNLCBFbGkgWmFyZXRza2lpIDxh IGhyZWY9Imh0dHA6Ly9lbGl6LWF0LWdudS5vcmciIHRhcmdldD0iX2JsYW5rIj5lbGl6LWF0LWdu dS5vcmc8L2E+IHxnbWFuZTMtaG9mZm1hbnwgPHNwYW4gZGlyPSJsdHIiPiZsdDs8YSBocmVmPSJt YWlsdG86MHdkcDNwMnhydEBzbmVha2VtYWlsLmNvbSIgdGFyZ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KgwqDCoMKg wqDCoMKgwqDCoMKgwqDCoMKgwqDCoMKgwqDCoMKgwqDCoMKgwqDCoMKgIChzZXRxIGkgc3RyLWxl bmd0aCkpKSk8YnI+PGJyPj09PT08YnI+PC9kaXY+PGRpdj5DaGFuZ2VMb2c6PGJyPjxicj4yMDE3 LTAxLTIzwqAgTWljaGFlbCBIb2ZmbWFuwqAgJmx0OzxhIGhyZWY9Im1haWx0bzplbWFjcy1ob2Zm bWFuQHNuZWFrZW1haWwuY29tIiB0YXJnZXQ9Il9ibGFuayI+ZW1hY3MtaG9mZm1hbkBzbmVha2Vt YWlsLmNvbTwvYT4mZ3Q7PGJyPjxicj48L2Rpdj48ZGl2PsKgICogdGVybS5lbCAodGVybS1lbXVs YXRlLXRlcm1pbmFsKTogZml4IGJ1ZyMxMTkxOTo8YnI+wqAgZG8gbm90IGRpc3BsYXkgP1wwMzIg ZXNjYXBlIGNvZGVzIGV2ZW4gd2hlbiBgaGFuZGxlZC1hbnNpLW1lc3NhZ2VgIGlzIHRydWU8YnI+ PC9kaXY+PC9kaXY+PC9kaXY+PC9kaXY+DQo= --001a1148f03af9b2840546c7f326-- From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 04:31:11 2017 Received: (at 11919-done) by debbugs.gnu.org; 27 Jan 2017 09:31:11 +0000 Received: from localhost ([127.0.0.1]:46975 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cX2sB-00064h-3y for submit@debbugs.gnu.org; Fri, 27 Jan 2017 04:31:11 -0500 Received: from eggs.gnu.org ([208.118.235.92]:43250) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cX2s9-00064U-GW for 11919-done@debbugs.gnu.org; Fri, 27 Jan 2017 04:31:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cX2s3-0004UV-9F for 11919-done@debbugs.gnu.org; Fri, 27 Jan 2017 04:31:04 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_50,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:60400) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cX2ry-0004Ta-Fx; Fri, 27 Jan 2017 04:30:58 -0500 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4042 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cX2rx-0005Zh-Ee; Fri, 27 Jan 2017 04:30:58 -0500 Date: Fri, 27 Jan 2017 11:30:46 +0200 Message-Id: <83mvec26k9.fsf@gnu.org> From: Eli Zaretskii To: Michael Hoffman In-reply-to: (message from Michael Hoffman on Mon, 23 Jan 2017 14:24:28 -0500) Subject: Re: bug#11919: 24.1; term-emulate-term does not process bash's Ctrl-Z signal of directory name when an AnSi message is present References: <26119-1485194282-859484@sneakemail.com> <83ziih3aic.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -8.2 (--------) X-Debbugs-Envelope-To: 11919-done Cc: 11919-done@debbugs.gnu.org, 0wdp3p2xrt@sneakemail.com, gmane3-hoffman@snkmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -8.2 (--------) > From: Michael Hoffman > Date: Mon, 23 Jan 2017 14:24:28 -0500 > Cc: 11919@debbugs.gnu.org, Michael Hoffman > > See these messages in the archives for the reason why that change was > done: > > https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-11/msg00020.html > https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-11/msg00103.html > https://lists.gnu.org/archive/html/emacs-pretest-bug/2005-12/msg00089.html > > If you can propose changes that solve this issue without > re-introducing that one, please do. > > The below patch eliminates the garbage printing while maintaining the behavior added in 2005 of having > `handled-ansi-message` preventing any updates to `default-directory` based on a \032 escape. Thanks, I pushed this to the master branch, with a slight change due to changes in the surrounding code since the version you were using. Please test the master branch, if you can, and please reopen the bug if some issues are left. From unknown Tue Jun 17 20:19:06 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 24 Feb 2017 12:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator