Don't try to do anything with the input history if MALLOC() for the buffer

failed.

This broke early debugging.
This commit is contained in:
Mike Smith 1997-11-07 02:34:50 +00:00
parent 19a41f3ab7
commit e7c818b53b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=31005

View File

@ -23,7 +23,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
* $Id: db_input.c,v 1.18 1997/04/12 17:35:02 joerg Exp $
* $Id: db_input.c,v 1.19 1997/08/17 21:21:50 joerg Exp $
*/
/*
@ -337,7 +337,7 @@ db_readline(lstart, lsize)
db_printf("\n"); /* synch output position */
*db_le = 0;
if (db_le - db_lbuf_start > 1) {
if (db_lhistory && (db_le - db_lbuf_start > 1)) {
/* Maintain input line history for non-empty lines. */
if (++db_lhistidx == DB_LHIST_NLINES) {
/* Rotate history. */