diff options
Diffstat (limited to 'lib/readline/history.c')
-rw-r--r-- | lib/readline/history.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/readline/history.c b/lib/readline/history.c index cd3e9392..1181e7cc 100644 --- a/lib/readline/history.c +++ b/lib/readline/history.c @@ -318,7 +318,7 @@ add_history_time (string) { HIST_ENTRY *hs; - if (string == 0) + if (string == 0 || history_length < 1) return; hs = the_history[history_length - 1]; FREE (hs->timestamp); |