From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?=E5=86=85=E8=97=A4_?= =?UTF-8?Q?=E7=A5=90=E4=B8=80=E9=83=8E?= Newsgroups: gmane.emacs.bugs Subject: bug#39399: tramp depends on unstable details of shell command line processing Date: Tue, 28 Jul 2020 11:51:42 +0900 Message-ID: References: <78F0CA89-AE48-4E45-B03B-7C6AABE9FCAC@gmail.com> <87lfj4omzu.fsf@gmx.de> Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.1\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36271"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 39399@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jul 28 04:52:13 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k0Fiu-0009Kd-U0 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 28 Jul 2020 04:52:12 +0200 Original-Received: from localhost ([::1]:58682 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1k0Fit-0000DW-BT for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 27 Jul 2020 22:52:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41018) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1k0Fil-0000DO-PX for bug-gnu-emacs@gnu.org; Mon, 27 Jul 2020 22:52:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:45052) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1k0Fik-0000bg-Es for bug-gnu-emacs@gnu.org; Mon, 27 Jul 2020 22:52:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1k0Fik-0003Kr-Cq for bug-gnu-emacs@gnu.org; Mon, 27 Jul 2020 22:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?=E5=86=85=E8=97=A4_?= =?UTF-8?Q?=E7=A5=90=E4=B8=80=E9=83=8E?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 28 Jul 2020 02:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39399 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 39399-submit@debbugs.gnu.org id=B39399.159590471312797 (code B ref 39399); Tue, 28 Jul 2020 02:52:02 +0000 Original-Received: (at 39399) by debbugs.gnu.org; 28 Jul 2020 02:51:53 +0000 Original-Received: from localhost ([127.0.0.1]:56593 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k0Fib-0003KL-E5 for submit@debbugs.gnu.org; Mon, 27 Jul 2020 22:51:53 -0400 Original-Received: from mail-pl1-f170.google.com ([209.85.214.170]:39162) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k0FiZ-0003K0-Ke for 39399@debbugs.gnu.org; Mon, 27 Jul 2020 22:51:52 -0400 Original-Received: by mail-pl1-f170.google.com with SMTP id b9so9144414plx.6 for <39399@debbugs.gnu.org>; Mon, 27 Jul 2020 19:51:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=MuSOfMwVzoQ2SjSOgZMk4Mc1cmrEqJySEqNOZfJ+P2w=; b=qI7O/OHNVRBS5rJTFEW/4dmiOeyi21UxuMCN4f9TCamza3/wpo5giNqzMW57FSIWca GZBK4f3yK426R/rmlsEHuizkLuM0P5zsUwajFp0pMVcV9M0p8lPuyAjvo+sDT77u0RTq Wh7OgrgKFm7OaQyx3VSMBellKNjQ0SLJ2XVN5oCiu3Ubtu7kZGvySrSNS1T0c6+vCYG0 JlDpvKMiCjIUwc1GgI/dFaDEFt+4mQd+jRIb+5+P/5bd70PZXv81us2XUyMToi2reGZq /YUd+/PKVfibqmSQm7dIom7u2fkSqsnXDhpL/GIfEVUutSnzIcrQ+Pm6XsHjI9FKJyQ1 TD1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=MuSOfMwVzoQ2SjSOgZMk4Mc1cmrEqJySEqNOZfJ+P2w=; b=Gwfzgi5OP9tiooBxZq4dzR/eogmqjl0rFYr44du86uNK08L37I/zmsv5bYwiUhw3zr /QYQPx7d5G/zdaSKj0Ee5VBglzVkHEdsIJAdEVPw5qCCoO5i/X+FxejuhWt+MTX09O6w 6T3upbYZlQ6+IadBiJ0aa5fws0k6WzrpXYy+gKIIcdhjIhaylRAAYibJo3LT6ULNfFD3 o/h3nFukOMEn5yTgJn85KXML8xBi9XfJTIvmFmJlu/cpGflL+KXo8y4IvmE4EBQjD0P2 v5ib8HhNDS5UmhPaqb/HBWt/zjeCp7ZdhrUr5iRPKG2oWNZkxBYGoB0M1DgTR7JkKFoj 7nMQ== X-Gm-Message-State: AOAM531avhX3USsK/tMuaLafVFAt8PonpzUi0UV0lFycAsD5Cn5vHyVN 8Bj7ffxmA+579ZM0uka/DMU= X-Google-Smtp-Source: ABdhPJwecg3BhLuQH6SxJHPXJm9V0uOPDbtsuWmgvu1ZuIu9C+Ifcws2nHBEWBKvvqlulO/0KRHPVg== X-Received: by 2002:a17:90a:4682:: with SMTP id z2mr2286543pjf.34.1595904705604; Mon, 27 Jul 2020 19:51:45 -0700 (PDT) Original-Received: from ?IPv6:2400:2410:3241:ef00:92:6c93:21:2aff? ([2400:2410:3241:ef00:92:6c93:21:2aff]) by smtp.gmail.com with ESMTPSA id d9sm16790898pgv.45.2020.07.27.19.51.44 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 27 Jul 2020 19:51:44 -0700 (PDT) In-Reply-To: <87lfj4omzu.fsf@gmx.de> X-Mailer: Apple Mail (2.3608.120.23.2.1) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:183614 Archived-At: Thanks for the reply. > 2020/07/28 3:01=E3=80=81Michael Albinus = =E3=81=AE=E3=83=A1=E3=83=BC=E3=83=AB: >> I could find a another way to solve this problem that avoids changing >> ~/.editrc and it's more simple. >> See my patch attached on this mail. >>=20 >> This problem happens on the latest libedit and FreeBSD sh uses Emacs >> edit mode by default. >>=20 >> If libedit runs on edit mode, libedit rewrites line by each control = character. >> On '^H', libedit sends line feed and write characters on the line = that >> is held in the internal screen buffer of libedit. >>=20 >> If edit mode turns off, line edit works on terminal that is as same = as >> previous behavior. >>=20 >> Shell command `set +E` escapes from edit mode in spite of libedit has >> two edit mode (Emacs and Vi). `set +E` disables both of them. >>=20 >> Although libedit has been developed and used by NetBSD, NetBSD = doesn=E2=80=99t >> have this problem. >> Because NetBSD sh doesn't use edit mode by default. >=20 > Thanks for the report. However, your patch is not applicable in = general, > because the "+E" option is not POSIX conform, and it isn't supported = by > all shells. I thought already about this when I was fixing bug#39399. >=20 > But wait - "set +o emacs +o vi" might give the same effect, and it is > much more supported by shells. And reading the sources, Tramp calls it > already (might have been added by Kai, many years ago). Maybe it is > sufficient to move it earlier in the initialization machinery? Exactly yes it is! =E2=80=9C set +o emacs +o vi=E2=80=9D works as same as =E2=80=9Cset = +E=E2=80=9D on FreeBSD sh. Tramp-mode hung before it, so it was not executed. > Appended is a patch for Tramp 2.4.4. You might install it from GNU > ELPA. Please check, whether this works for you. The appended patch works for me. But I think just moving "set +o emacs +o vi=E2=80=9D before =E2=80=9Cstty = =E2=80=A6=E2=80=9D is more simple way. =E2=80=94 Yuichiro NAITO naito.yuichiro@gmail.com