From 1f9e761d2055db367fac790b0e5218b196ed02d1 Mon Sep 17 00:00:00 2001 From: Karl Heuer Date: Fri, 8 Apr 1994 06:57:27 +0000 Subject: [PATCH] (comint-exec-1): Handle both termcap and terminfo. --- lisp/comint.el | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lisp/comint.el b/lisp/comint.el index 11e49d4fdb7..8be11e72219 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -553,9 +553,13 @@ buffer. The hook `comint-exec-hook' is run after each exec." (defun comint-exec-1 (name buffer command switches) (let ((process-environment - (nconc (list "EMACS=t" "TERM=emacs" - (format "TERMCAP=emacs:co#%d:tc=unknown" (frame-width))) - process-environment))) + (nconc + (if (and (boundp 'system-uses-terminfo) system-uses-terminfo) + (list "EMACS=t" "TERM=unknown" + (format "COLUMNS=%d" (frame-width))) + (list "EMACS=t" "TERM=emacs" + (format "TERMCAP=emacs:co#%d:tc=unknown" (frame-width)))) + process-environment))) (apply 'start-process name buffer command switches))) ;;; Input history processing in a buffer -- 2.39.5