Module Name: src Committed By: christos Date: Tue Jan 21 13:51:44 UTC 2014
Modified Files: src/lib/libedit: readline.c Log Message: ... if called prior to using_history(). This needed to be worked around in PHP: http://git.php.net/?p=php-src.git;a=commitdiff;h=31d67bd3 Bug: https://bugzilla.redhat.com/show_bug.cgi?id=1055409 To generate a diff of this commit: cvs rdiff -u -r1.109 -r1.110 src/lib/libedit/readline.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/readline.c diff -u src/lib/libedit/readline.c:1.109 src/lib/libedit/readline.c:1.110 --- src/lib/libedit/readline.c:1.109 Wed Aug 28 04:05:21 2013 +++ src/lib/libedit/readline.c Tue Jan 21 08:51:44 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: readline.c,v 1.109 2013/08/28 08:05:21 christos Exp $ */ +/* $NetBSD: readline.c,v 1.110 2014/01/21 13:51:44 christos Exp $ */ /*- * Copyright (c) 1997 The NetBSD Foundation, Inc. @@ -31,7 +31,7 @@ #include "config.h" #if !defined(lint) && !defined(SCCSID) -__RCSID("$NetBSD: readline.c,v 1.109 2013/08/28 08:05:21 christos Exp $"); +__RCSID("$NetBSD: readline.c,v 1.110 2014/01/21 13:51:44 christos Exp $"); #endif /* not lint && not SCCSID */ #include <sys/types.h> @@ -1482,6 +1482,9 @@ clear_history(void) { HistEvent ev; + if (h == NULL || e == NULL) + rl_initialize(); + (void)history(h, &ev, H_CLEAR); history_length = 0; }