Module Name:    src
Committed By:   christos
Date:           Tue Dec  8 12:56:55 UTC 2015

Modified Files:
        src/lib/libedit: el.c

Log Message:
Only reset the terminal if we have a tty (Boris Ranto)


To generate a diff of this commit:
cvs rdiff -u -r1.73 -r1.74 src/lib/libedit/el.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libedit/el.c
diff -u src/lib/libedit/el.c:1.73 src/lib/libedit/el.c:1.74
--- src/lib/libedit/el.c:1.73	Wed Jun 18 14:12:28 2014
+++ src/lib/libedit/el.c	Tue Dec  8 07:56:55 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: el.c,v 1.73 2014/06/18 18:12:28 christos Exp $	*/
+/*	$NetBSD: el.c,v 1.74 2015/12/08 12:56:55 christos Exp $	*/
 
 /*-
  * Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
 #if 0
 static char sccsid[] = "@(#)el.c	8.2 (Berkeley) 1/3/94";
 #else
-__RCSID("$NetBSD: el.c,v 1.73 2014/06/18 18:12:28 christos Exp $");
+__RCSID("$NetBSD: el.c,v 1.74 2015/12/08 12:56:55 christos Exp $");
 #endif
 #endif /* not lint && not SCCSID */
 
@@ -135,7 +135,8 @@ el_end(EditLine *el)
 	terminal_end(el);
 	keymacro_end(el);
 	map_end(el);
-	tty_end(el);
+	if (!(el->el_flags & NO_TTY))
+		tty_end(el);
 	ch_end(el);
 	search_end(el);
 	hist_end(el);

Reply via email to