From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Phil Sainty Newsgroups: gmane.emacs.bugs Subject: bug#31193: 26.1; error in `term-down' after window configuration change Date: Wed, 18 Apr 2018 01:00:14 +1200 Message-ID: <5480f11459b73e4cf0aabe12da5ce675@webmail.orcon.net.nz> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1523970155 14694 195.159.176.226 (17 Apr 2018 13:02:35 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 17 Apr 2018 13:02:35 +0000 (UTC) User-Agent: Orcon Webmail To: 31193@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Apr 17 15:02:30 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1f8QFi-0003iY-HB for geb-bug-gnu-emacs@m.gmane.org; Tue, 17 Apr 2018 15:02:30 +0200 Original-Received: from localhost ([::1]:37535 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f8QHp-0007KM-8l for geb-bug-gnu-emacs@m.gmane.org; Tue, 17 Apr 2018 09:04:41 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60048) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f8QEM-00050X-P4 for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:01:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f8QEI-0008U8-LS for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:01:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48956) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f8QEI-0008U0-IM for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:01:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1f8QEI-0007Pz-B7 for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:01:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Phil Sainty Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 17 Apr 2018 13:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 31193 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.152397004828485 (code B ref -1); Tue, 17 Apr 2018 13:01:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 17 Apr 2018 13:00:48 +0000 Original-Received: from localhost ([127.0.0.1]:56853 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1f8QE3-0007PN-MT for submit@debbugs.gnu.org; Tue, 17 Apr 2018 09:00:48 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:40633) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1f8QE1-0007P6-Ja for submit@debbugs.gnu.org; Tue, 17 Apr 2018 09:00:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f8QDs-0008D9-Ey for submit@debbugs.gnu.org; Tue, 17 Apr 2018 09:00:40 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:39805) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1f8QDs-0008D2-BP for submit@debbugs.gnu.org; Tue, 17 Apr 2018 09:00:36 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59763) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f8QDl-0004hG-V0 for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:00:35 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f8QDb-00085O-Tu for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:00:30 -0400 Original-Received: from smtp-3.orcon.net.nz ([60.234.4.44]:40001) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f8QDb-000838-Hy for bug-gnu-emacs@gnu.org; Tue, 17 Apr 2018 09:00:19 -0400 Original-Received: from [10.253.37.70] (port=56611 helo=webmail.orcon.net.nz) by smtp-3.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1f8QDX-0002ei-25 for bug-gnu-emacs@gnu.org; Wed, 18 Apr 2018 01:00:15 +1200 Original-Received: from [150.107.175.140] via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Wed, 18 Apr 2018 01:00:14 +1200 X-Sender: psainty@orcon.net.nz X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:145487 Archived-At: In a `term' buffer, seemingly after any window configuration change, the process filter triggers an error due to `term-current-row' being nil unexpectedly. Recipe: emacs -Q M-x toggle-debug-on-error M-x term RET RET #repeatedly -- all is fine at this point... C-c 2 RET Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil) term-down(1 t) term-emulate-terminal(# "\015\033[K$ \015\n\032//home/phil\015\n") That window config change could be C-c 2 or C-c 3 or, if already split, C-c 1; it doesn't seem to matter. With an uncompiled `term-down': Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil) =(nil 0) (and (= term-current-row 0) (< down 0)) (if (and (= term-current-row 0) (< down 0)) ...) (let ((start-column (term-horizontal-column))) ...) term-down(1 t) term-emulate-terminal(# "\015\033[K$ \015\n\032//home/phil\015\n") That test of (= term-current-row 0) occurs twice in the function. Trivially, testing (bound-and-true-p term-current-row) beforehand in both pieces of code circumvents the error and appears in practice to resolve the issue, but I don't know whether that's the *right* fix. -Phil In GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2018-04-15 built on shodan Windowing system distributor 'The X.Org Foundation', version 11.0.11804000 System Description: Ubuntu 16.04.4 LTS Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Debug on Error enabled globally Entering debugger... term-emulate-terminal: Wrong type argument: number-or-marker-p, nil Configured using: 'configure --prefix=/home/phil/emacs/26.1rc1/usr/local --with-x-toolkit=lucid --without-sound' Configured features: XAW3D XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK DBUS GSETTINGS NOTIFY GNUTLS LIBXML2 FREETYPE XFT ZLIB TOOLKIT_SCROLL_BARS LUCID X11 THREADS LCMS2 Important settings: value of $LANG: en_NZ.UTF-8 locale-coding-system: utf-8-unix Major mode: Debugger Minor modes in effect: tooltip-mode: t global-eldoc-mode: t electric-indent-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 buffer-read-only: t line-number-mode: t transient-mark-mode: (only . t) Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message rmc puny seq dired dired-loaddefs format-spec rfc822 mml mml-sec password-cache epa derived epg epg-config gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils help-mode cl-print byte-opt gv bytecomp byte-compile cl-loaddefs cl-lib cconv debug term disp-table easymenu ehelp ring cus-start cus-load elec-pair time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 108699 9507) (symbols 48 22248 1) (miscs 40 76 129) (strings 32 32773 1265) (string-bytes 1 829787) (vectors 16 14995) (vector-slots 8 503659 11454) (floats 8 61 115) (intervals 56 287 0) (buffers 992 13) (heap 1024 42349 1368))