summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChet Ramey <chet.ramey@case.edu>2011-11-23 19:21:47 -0500
committerChet Ramey <chet.ramey@case.edu>2011-11-23 19:21:47 -0500
commitff2d9ff725d1d8591f3534ed2a992b550b56a832 (patch)
tree701ab74a43fdcc7aa2191b87c820ee3cf1400740
parent8e82c61d4caacfd43668bf1d2a7e23a0a21fa5bc (diff)
downloadreadline-ff2d9ff725d1d8591f3534ed2a992b550b56a832.tar.gz
Readline-6.0.005 import
-rw-r--r--CHANGELOG5
-rw-r--r--CHANGELOG~1021
-rw-r--r--CHANGES2
-rw-r--r--CHANGES~1098
-rw-r--r--NEWS3
-rw-r--r--NEWS~39
-rw-r--r--complete.c12
-rw-r--r--display.c23
-rw-r--r--patchlevel2
-rw-r--r--readline.h3
-rw-r--r--terminal.c2
11 files changed, 2202 insertions, 8 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 432746e..fe2b8f3 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1019,3 +1019,8 @@ configure.in
----
support/config.{guess,sub}
- updated to newer versions from autoconf-2.62 distribution
+
+ 9/6
+ ---
+{configure,config.h}.in
+ - add AC_SYS_LARGEFILE and consequent #defines for large file support
diff --git a/CHANGELOG~ b/CHANGELOG~
new file mode 100644
index 0000000..432746e
--- /dev/null
+++ b/CHANGELOG~
@@ -0,0 +1,1021 @@
+[Readline-specific changelog. Descriptions of changes to the source are
+ found in the bash changelog.]
+
+ 6/9
+ ---
+Makefile.in
+ - quote value of ${INSTALL_DATA} when passing it to makes in
+ subdirectories
+
+ 7/1
+ ---
+Makefile.in
+ - don't pass INSTALL_DATA to a make in the `doc' subdirectory; let
+ autoconf set the value itself in the Makefile
+ - removed a stray `-' before $(RANLIB) in the `install' recipe
+
+doc/Makefile.in
+ - add a VPATH assignment so the documentation is not remade if it's
+ already up-to-date in the distribution
+
+configure.in
+ - call AC_SUBST(LOCAL_LDFLAGS), since Makefile.in contains
+ @LOCAL_LDFLAGS@
+
+ 7/9
+ ---
+
+config.h.in
+ - add define lines for STRUCT_WINSIZE_IN_SYS_IOCTL and
+ STRUCT_WINSIZE_IN_TERMIOS
+
+configure.in
+ - call BASH_STRUCT_WINSIZE to look for the definition of
+ `struct winsize'
+
+ 7/17
+ ----
+configure.in
+ - call AC_MINIX
+
+config.h.in
+ - add define line for AC_MINIX
+
+ 7/18
+ ----
+Makefile.in
+ - add `install-shared' and `uninstall-shared' targets
+
+ 8/4
+ ---
+Makefile.in
+ - install and uninstall libhistory.a in the `install' and
+ `uninstall' targets
+
+ 9/4
+ ---
+configure.in
+ - bumped LIBVERSION up to 2.1.1, indicating that this is patch
+ level 1 to release 2.1
+
+
+ 9/16
+ ----
+Makefile.in
+ - `make distclean' now descends into the `examples' subdir
+
+doc/Makefile.in
+ - the `distclean' and `maintainer-clean' targets should remove
+ Makefile
+
+examples/Makefile.in
+ - added the various clean targets
+
+ 4/2
+ ---
+configure.in
+ - bumped LIBVERSION up to 2.2
+
+ 4/18
+ ----
+[readline-2.2 released]
+
+ 4/20
+ ----
+Makefile.in
+ - make `libhistory.a' a dependency of `install'
+ - fixed a typo in the recipe for `install' that copied libreadline.a
+ to libhistory.old right after installing it
+
+ 4/27
+ ----
+doc/Makefile.in
+ - install {readline,history}.info out of the source directory if
+ they are not found in the current (build) directory -- only an
+ issue if the libraries are built in a different directory than
+ the source directory
+
+ 5/1
+ ---
+support/shobj-conf
+ - script from the bash distribution to do shared object and library
+ configuration
+
+shlib/Makefile.in
+ - new directory and makefile to handle building shared versions of
+ libreadline and libhistory, controlled by support/shobj-conf
+
+ 5/7
+ ---
+doc/Makefile.in
+ - set SHELL to /bin/sh, rather than relying on make to be correct
+
+ 5/14
+ ----
+savestring.c
+ - new file, moved from shell.c, for backwards compatibility
+
+Makefile.in, shlib/Makefile.in
+ - make sure savestring.c is compiled and added to libreadline and
+ libhistory
+
+[THERE ARE NO MORE #ifdef SHELL LINES IN THE C SOURCE FILES.]
+
+ 5/15
+ ----
+README
+ - updated description of shared library creation for the new scheme
+
+[THERE ARE NO MORE #ifdef SHELL LINES IN ANY OF THE SOURCE FILES.]
+
+Makefile.in
+ - bumped SHLIB_MAJOR up to 4 since we've augmented the library
+ API
+ - rlconf.h is now one of the installed headers, so applications can
+ find out whether things like vi-mode are available in the installed
+ libreadline
+
+ 5/20
+ ----
+configure.in
+ - changed RL_LIBRARY_VERSION to 4.0 to match the version of the
+ installed shared libraries
+
+ 6/5
+ ---
+rlstdc.h
+ - new file
+
+Makefile.in
+ - rlstdc.h is now one of the installed headers
+
+ 8/3
+ ---
+shlib/Makefile.in
+ - made the suffix rule that creates xx.so from xx.c write the
+ compiler output to `a.o', which is then mv'd to xx.so, because
+ some compilers (Sun WSpro 4.2, for example) don't allow any
+ suffixes other than `.o' for `cc -c' (not even `a.out')
+
+ 9/15
+ ----
+
+Makefile.in
+ - AR and ARFLAGS are now substituted by configure, used in recipes
+ that build the libraries
+
+configure.in
+ - use AC_CHECK_PROG to check for ar
+ - set ARFLAGS if it has not already been set in the environment
+
+ 10/5
+ ----
+Makefile.in
+ - removed savestring.o from object file list
+
+ 10/28
+ -----
+shlib/Makefile.in
+ - don't use a fixed filename in the .c.so suffix rule to avoid
+ problems with parallel makes
+
+ 12/21
+ -----
+support/shlib-install
+ - new script to install shared readline and history libraries
+
+shlib/Makefile.in
+ - changed to call shlib-install for install and uninstall targets
+
+[readline-4.0-beta1 frozen]
+
+ 12/22
+ -----
+configure.in
+ - call AC_SUBST for SHOBJ_XLDFLAGS and SHLIB_LIBS
+
+shlib/Makefile.in
+ - SHOBJ_XLDFLAGS and SHLIB_LIBS are now substituted by configure
+ - add $(SHLIB_LIBS) at end of command line that builds the shared
+ libraries (currently needed only by AIX 4.2)
+
+ 12/31
+ -----
+MANIFEST, MANIFEST.doc
+ - the TOC html files are no longer generated and no longer part of
+ the distribution
+
+ 2/18/1999
+ ---------
+configure.in
+ - set MAKE_SHELL to /bin/sh and substitute into the Makefiles
+
+Makefile.in,{doc,examples,shlib}/Makefile.in
+ - set SHELL from @MAKE_SHELL@
+
+[readline-4.0 released]
+
+ 3/11
+ ----
+doc/Makefile.in
+ - removed references to HTMLTOC, since separate HTML table-of-contents
+ files are no longer created
+
+examples/Makefile.in
+ - remove `*.exe' in clean target for MS-DOS
+
+Makefile.in
+ - make `readline' target depend on ./libreadline.a
+ - configure now substitutes TERMCAP_LIB into Makefile.in
+ - use ${TERMCAP_LIB} instead of -ltermcap in recipe for `readline'
+ - clean target now removes readline and readline.exe in case they
+ get built
+
+configure.in
+ - use `pwd.exe' to set BUILD_DIR on MS-DOS DJGPP
+
+ 3/15
+ ----
+support/shlib-install
+ - Irix 5.x and Irix 6.x should install shared libraries like Solaris 2
+ - changes for installing on hp-ux 1[01].x
+
+ 3/23
+ ----
+configure.in
+ - make sure that the $CC argument to shobj-conf is quoted
+
+ 4/8
+ ---
+
+xmalloc.h, rlprivate.h, rlshell.h
+ - new files
+
+Makefile.in,shlib/Makefile.in
+ - add dependencies on xmalloc.h, rlshell.h
+ - add xmalloc.h, rlprivate.h, rlshell.h to list of header files
+
+MANIFEST
+ - add xmalloc.h, rlprivate.h, rlshell.h
+
+ 4/9
+ ---
+Makefile.in,shlib/Makefile.in
+ - add dependencies on rlprivate.h
+
+ 4/13
+ ----
+doc/Makefile.in
+ - add variable, PSDVI, which is the desired resolution of the
+ generated postscript files. Set to 300 because I don't have
+ any 600-dpi printers
+ - set LANGUAGE= before calling makeinfo, so messages are in English
+ - add rluserman.{info,dvi,ps,html} to appropriate variables
+ - add rules to create rluserman.{info,dvi,ps,html}
+ - install and uninstall rluserman.info, but don't update the directory
+ file in $(infodir) yet
+
+MANIFEST
+ - add doc/rluserman.{texinfo,info,dvi,ps,html}
+
+ 4/30
+ ----
+configure.in
+ - updated library version to 4.1
+
+ 5/3
+ ---
+configure.in
+ - SHLIB_MAJOR and SHLIB_MINOR shared library version numbers are
+ constructed from $LIBRARY_VERSION and substituted into Makefiles
+
+ 5/5
+ ---
+support/shlib-install
+ - OSF/1 installs shared libraries like Solaris
+
+Makefile.in
+ - broke the header file install and uninstall into two new targets:
+ install-headers and uninstall-headers
+ - install and uninstall depend on install-headers and uninstall-headers
+ respectively
+ - changed install-shared and uninstall-shared targets to depend on
+ install-headers and uninstall-headers, respectively, so users may
+ choose to install only the shared libraries. I'm not sure about
+ the uninstall one yet -- maybe it should check whether or not
+ the static libraries are installed and not remove the header files
+ if they are
+
+ 9/3
+ ---
+configure.in, config.h.in
+ - added test for memmove (for later use)
+ - changed version to 4.1-beta1
+
+ 9/13
+ ----
+examples/rlfe.c
+ - Per Bothner's `rlfe' readline front-end program
+
+examples/Makefile.in
+ - added rules to build rlfe
+
+ 9/21
+ ----
+support/shlib-install
+ - changes to handle FreeBSD-3.x elf or a.out shared libraries, which
+ have different semantics and need different naming conventions
+
+ 1/24/2000
+ ---------
+doc/Makefile.in
+ - remove *.bt and *.bts on `make clean'
+
+ 2/4
+ ---
+
+
+configure.in
+ - changed LIBVERSION to 4.1-beta5
+
+ 3/17/2000
+ ---------
+[readline-4.1 released]
+
+ 3/23
+ ----
+Makefile.in
+ - remove the `-t' argument to ranlib in the install recipe; some
+ ranlibs don't have it and attempt to create a file named `-t'
+
+ 3/27
+ ----
+support/shlib-install
+ - install shared libraries unwritable by anyone on HP-UX
+ - changed symlinks to relative pathnames on all platforms
+
+shlib/Makefile.in
+ - added missing `includedir' assignment, substituted by configure
+
+Makefile.in
+ - added missing @SET_MAKE@ so configure can set $MAKE appropriately
+
+configure.in
+ - add call to AC_PROG_MAKE_SET
+
+ 8/30
+ ----
+shlib/Makefile.in
+ - change the soname bound into the shared libraries, so it includes
+ only the major version number. If it includes the minor version,
+ programs depending on it must be rebuilt (which may or may not be
+ a bad thing)
+
+ 9/6
+ ---
+examples/rlfe.c
+ - add -l option to log input and output (-a option appends to logfile)
+ - add -n option to set readline application name
+ - add -v, -h options for version and help information
+ - change a few things because getopt() is now used to parse arguments
+
+ 9/12
+ ----
+support/shlib-install
+ - fix up the libname on HPUX 11
+
+ 10/18
+ -----
+configure.in
+ - changed library version to 4.2-alpha
+
+ 10/30
+ -----
+configure.in
+ - add -fsigned-char to LOCAL_CFLAGS for Linux running on the IBM
+ S/390
+
+Makefile.in
+ - added new file, rltypedefs.h, installed by default with `make install'
+
+ 11/2
+ ----
+compat.c
+ - new file, with backwards-compatibility function definitions
+
+Makefile.in,shlib/Makefile.in
+ - make sure that compat.o/compat.so are built and linked apppropriately
+
+support/shobj-conf
+ - picked up bash version, which means that shared libs built on
+ linux and BSD/OS 4.x will have an soname that does not include
+ the minor version number
+
+ 11/13
+ -----
+examples/rlfe.c
+ - rlfe can perform filename completion for relative pathnames in the
+ inferior process's context if the OS supports /proc/PID/cwd (linux
+ does it OK, Solaris is slightly warped, none of the BSDs have it)
+
+ 11/17/2000
+ ----------
+[readline-4.2-alpha released]
+
+ 11/27
+ -----
+Makefile.in,shlib/Makefile.in
+ - added dependencies for rltypedefs.h
+
+shlib/Makefile.in
+ - changed dependencies on histlib.h to $(topdir)/histlib.h
+
+ 1/22
+ ----
+configure.in
+ - changed release version to 4.2-beta
+
+ 2/2
+ ---
+examples/Makefile.in
+ - build histexamp as part of the examples
+
+ 2/5
+ ---
+doc/Makefile.in
+ - don't remove the dvi, postscript, html, info, and text `objects'
+ on a `make distclean', only on a `make maintainer-clean'
+
+ 3/6
+ ---
+doc/history.{0,3}, doc/history_3.ps
+ - new manual page for history library
+
+doc/Makefile.in
+ - rules to install and uninstall history.3 in ${man3dir}
+ - rules to build history.0 and history_3.ps
+
+ 4/2
+ ---
+configure.in
+ - changed LIBVERSION to `4.2'
+
+ 4/5
+ ---
+[readline-4.2 frozen]
+
+ 4/9
+ ---
+[readline-4.2 released]
+
+ 5/2
+ ---
+Makefile.in,{doc,examples,shlib}/Makefile.in
+ - added support for DESTDIR installation root prefix, to support
+ building packages
+
+doc/Makefile.in
+ - add an info `dir' file entry for rluserman.info on `make install'
+ - change man1ext to `.1' and man3ext to `.3'
+ - install man pages with a $(man3ext) extension in the target directory
+ - add support for installing html documentation if `htmldir' has a
+ value
+
+Makefile.in
+ - on `make install', install from the `shlib' directory, too
+ - on `make uninstall', uninstall in the `doc' and `shlib'
+ subdirectories, too
+
+support/shlib-install
+ - add `freebsdelf*', `freebsdaout*', Hurd, `sysv4*', `sysv5*', `dgux*'
+ targets for symlink creation
+
+ 5/7
+ ---
+configure.in, config.h.in
+ - check for <limits.h>, define HAVE_LIMITS_H if found
+
+ 5/8
+ ---
+aclocal.m4
+ - pick up change to BASH_CHECK_LIB_TERMCAP that adds check for
+ libtinfo (termcap-specific portion of ncurses-5.2)
+
+ 5/9
+ ---
+configure.in
+ - call AC_C_CONST to find out whether or not the compiler supports
+ `const'
+
+config.h.in
+ - placeholder for `const' define, if any
+
+ 5/10
+ ----
+configure.in
+ - fix AC_CHECK_PROG(ar, ...) test to specify right value for the
+ case where ar is not found; should produce a better error message
+
+ 5/14
+ ----
+configure.in,config.h.in
+ - check for vsnprintf, define HAVE_VSNPRINTF if found
+
+ 5/21
+ ----
+configure.in, config.h.in
+ - add checks for size_t, ssize_t
+
+ 5/30
+ ----
+configure.in
+ - update autoconf to version 2.50, use in AC_PREREQ
+ - changed AC_INIT to new flavor
+ - added AC_CONFIG_SRCDIR
+ - AC_CONFIG_HEADER -> AC_CONFIG_HEADERS
+ - call AC_C_PROTOTYPES
+ - AC_RETSIGTYPE -> AC_TYPE_SIGNAL
+
+ 8/22
+ ----
+configure.in
+ - updated the version number to 4.2a
+
+Makefile.in,shlib/Makefile.in
+ - make sure tilde.o is built -DREADLINE_LIBRARY when being built as
+ part of the standalone library, so it picks up the right include
+ files
+
+ 8/23
+ ----
+support/shlib-install
+ - support for Darwin/MacOS X shared library installation
+
+ 9/24
+ ----
+examples/readlinebuf.h
+ - a new file, a C++ streambuf interface that uses readline for I/O.
+ Donated by Dimitris Vyzovitis <vyzo@media.mit.edu>
+
+ 10/9
+ ----
+configure.in
+ - replaced call to BASH_HAVE_TIOCGWINSZ with AC_HEADER_TIOCGWINSZ
+
+[readline-4.2a-beta1 frozen]
+
+ 10/15
+ -----
+configure.in, config.h.in
+ - check for <memory.h>, define HAVE_MEMORY_H if found
+ - check for <strings.h>, define HAVE_STRINGS_H if found
+
+ 10/18
+ -----
+configure.in, config.h.in
+ - check for isascii, define HAVE_ISASCII if found
+
+configure.in
+ - changed the macro names from bash as appropriate:
+ BASH_SIGNAL_CHECK -> BASH_SYS_SIGNAL_VINTAGE
+ BASH_REINSTALL_SIGHANDLERS -> BASH_SYS_REINSTALL_SIGHANDLERS
+ BASH_MISC_SPEED_T -> BASH_CHECK_SPEED_T
+
+ 10/22
+ -----
+configure.in
+ - check for isxdigit with AC_CHECK_FUNCS
+
+config.h.in
+ - new define for HAVE_ISXDIGIT
+
+ 10/29
+ -----
+configure.in, config.h.in
+ - check for strpbrk with AC_CHECK_FUNCS, define HAVE_STRPBRK if found
+
+ 11/1
+ ----
+Makefile.in
+ - make sure DESTDIR is passed to install and uninstall makes in
+ subdirectories
+ - when saving old copies of installed libraries, make sure we use
+ DESTDIR for the old installation tree
+
+[readline-4.2a-rc1 frozen]
+
+ 11/2
+ ----
+Makefile.in, shlib/Makefile.in
+ - don't put -I$(includedir) into CFLAGS
+
+ 11/15
+ -----
+[readline-4.2a released]
+
+ 11/20
+ -----
+examples/rlcat.c
+ - new file
+
+examples/Makefile.in
+ - changes for rlcat
+
+ 11/28
+ -----
+configure.in
+ - default TERMCAP_LIB to -lcurses if $prefer_curses == yes (as when
+ --with-curses is supplied)
+
+examples/Makefile.in
+ - substitute @LDFLAGS@ in LDFLAGS assignment
+
+ 11/29
+ -----
+config.h.in
+ - add necessary defines for multibyte include files and functions
+ - add code to define HANDLE_MULTIBYTE if prerequisites are met
+
+configure.in
+ - call BASH_CHECK_MULTIBYTE
+
+ 12/14
+ -----
+config.h.in
+ - add #undef PROTOTYPES, filled in by AC_C_PROTOTYPES
+
+ 12/17
+ -----
+config.h.in
+ - moved HANDLE_MULTIBYTE code to rlmbutil.h
+
+rlmbutil.h, mbutil.c
+ - new files
+
+Makefile.in, shlib/Makefile.in
+ - added rules for mbutil.c
+
+ 12/20
+ -----
+configure.in
+ - added --enable-shared, --enable-static options to configure to
+ say which libraries are built by default (both default to yes)
+ - if SHLIB_STATUS == 'unsupported', turn off default shared library
+ building
+ - substitute new STATIC_TARGET, SHARED_TARGET, STATIC_INSTALL_TARGET,
+ and SHARED_INSTALL_TARGET
+
+Makefile.in
+ - `all' target now depends on (substituted) @STATIC_TARGET@ and
+ @SHARED_TARGET@
+ - `install' target now depends on (substituted) @STATIC_INSTALL_TARGET@
+ and @SHARED_INSTALL_TARGET@
+
+INSTALL, README
+ - updated with new info about --enable-shared and --enable-static
+
+ 1/10/2002
+ ---------
+configure.in
+ - bumped the library version number to 4.3
+
+ 1/24
+ ----
+Makefile.in,shlib/Makefile.in
+ - changes for new file, text.c, with character and text handling
+ functions from readline.c
+
+ 2/20
+ ----
+{configure.config.h}.in
+ - call AC_C_CHAR_UNSIGNED, define __CHAR_UNSIGNED__ if chars are
+ unsigned by default
+
+ 5/20
+ ----
+doc/Makefile.in
+ - new maybe-clean target that removes the generated documentation if
+ the build directory differs from the source directory
+ - distclean target now depends on maybe-clean
+
+ 7/17
+ ----
+[readline-4.3 released]
+
+ 7/18
+ ----
+shlib/Makefile.in
+ - fix bad dependency: text.so: terminal.c, make it depend on text.c
+
+ 8/7
+ ---
+support/shlib-install
+ - break `linux' out into its own stanza: it seems that linux
+ distributions are all moving to the following scheme:
+
+ libreadline.so.4.3 installed version
+ libreadline.so.4 -> libreadline.so.4.3 symlink
+ libreadline.so -> libreadline.so.4 symlink
+
+ 10/29
+ -----
+support/shlib-install
+ - change INSTALL_LINK[12] to use `&&' instead of `;' so it only
+ tries the link if the cd succeeds; put ${echo} in there, too
+ - use $LN instead of `ln -s' so it works on machines without symlinks
+ - change special linux stanza to use cd before ln also
+ - change to use $INSTALL_LINK1 and $INSTALL_LINK2 appropriately
+ instead of explicit commands in various stanzas
+
+ 2/1
+ ---
+config.h.in
+ - add HAVE_MBRTOWC and HAVE_MBRLEN
+ - add NO_MULTIBYTE_SUPPORT for new configure argument
+ - add STDC_HEADERS
+
+configure.in
+ - new argument --enable-multibyte (enabled by default), allows
+ multibyte support to be turned off even on systems that support it
+ - add check for ansi stdc headers with call to AC_HEADER_STDC
+
+ 2/3
+ ---
+configure.in
+ - add call to BASH_FUNC_CTYPE_NONASCII
+
+config.h.in
+ - add CTYPE_NON_ASCII
+
+ 2/20
+ ----
+
+doc/manvers.texinfo
+ - renamed to version.texi to match other GNU software
+ - UPDATE-MONTH variable is now `UPDATED-MONTH'
+
+doc/{hist,rlman,rluserman}.texinfo
+ - include version.texi
+
+doc/{rltech,rluser,hstech,hsuser}.texi
+ - changed the suffix from `texinfo' to `texi'
+
+doc/Makefile.in
+ - made appropriate changes for {{rl,hs}tech,{rl,hs}user}.texi
+
+doc/{rlman,rluserman}.texinfo
+ - changed the suffix from `texinfo' to `texi'
+
+doc/hist.texinfo
+ - renamed to history.texi to be more consistent
+
+ 6/11
+ ----
+shlib/Makefile.in
+ - have configure substitute value of `@LDFLAGS@' into the assignment
+ to SHLIB_XLDFLAGS
+
+ 6/16
+ ----
+configure.in
+ - readline and history libraries are now at version 5.0
+
+ 8/18
+ ----
+support/shlib-install
+ - support for FreeBSD-gnu (from Robert Millan)
+
+ 12/4
+ ----
+Makefile.in
+ - add variables for localedir and the PACKAGE_* variables, auto-set
+ by configure
+
+ 12/9
+ ----
+Makefile.in
+ - use mkinstalldirs instead of mkdirs
+
+ 4/22
+ ----
+Makefile.in
+ - separate doc install/uninstall out into two new targets:
+ install-doc and uninstall-doc
+ - make install-doc and uninstall-doc prerequisites of appropriate
+ install and uninstall targets
+
+examples/rl-fgets.c
+ - new example from Harold Levy that wraps fgets replacement functions
+ that call readline in a shared library that can be interposed with
+ LD_PRELOAD
+
+ 7/27
+ ----
+[readline-5.0 released]
+
+ 11/15
+ -----
+examples/rlfe/{ChangeLog,Makefile.in,README,config.h.in,configure,configure.in,extern.h,os.h,pty.c,rlfe.c,screen.h}
+ - new version of rlfe, rlfe-0.4, from Per Bothner; now a standalone
+ application
+
+ 11/16
+ -----
+shlib/Makefile.in
+ - substitute TERMCAP_LIB in from configure
+
+configure.in
+ - if SHLIB_LIBS doesn't include a termcap library (curses, ncurses,
+ termcap, termlib), append the value of $TERMCAP_LIB to it
+
+ 11/30
+ -----
+configure.in
+ - take out change from 11/16; it doesn't work for some systems (e.g.,
+ SunOS 4.x and Solaris 2.6)
+ - add support for --enable-purify configure argument
+ - pass TERMCAP_LIB in environment when calling shobj-conf
+
+examples/Makefile.in
+ - add support for building examples with purify
+
+ 1/23/2005
+ ---------
+configure.in
+ - set BUILD_DIR to contain backslashes to escape any spaces in the
+ directory name -- this is what make will accept in targets and
+ prerequisites, so it's better than trying to use double quotes
+
+ 2/25
+ ----
+configure.in
+ - change check for sys/ptem.h to include sys/stream.h if present, to
+ avoid the `present but cannot be compiled' messages on Solaris and
+ SVR4.2 (does anyone still use SVR4.2?)
+
+ 5/7
+ ---
+configure.in
+ - add cross-compiling support from the bash configure.in, which cygwin
+ and mingw have apparently adopted
+ - add check for pwd.h, fcntl.h
+ - add checks for fcntl, kill system calls
+ - add checks for getpw{ent,nam,uid} C library functions
+ - pass a compile-time option through to Makefiles if cross-compiling
+
+config.h.in
+ - add HAVE_PWD_H for <pwd.h>, HAVE_FCNTL_H for <fcntl.h>
+ - add HAVE_FCNTL, HAVE_KILL for respective system calls
+ - add HAVE_GETPW{ENT,NAM,UID} for passwd functions
+
+Makefile.in,shlib/Makefile.in
+ - @CROSS_COMPILE@ is substituted into DEFS (equal to -DCROSS_COMPILING
+ if bash is being cross-compiled)
+
+ 8/2
+ ---
+examples/Makefile.in
+ - use $(READLINE_LIB) instead of -lreadline to get around MacOS X 10.4's
+ preference for (incompatible) shared libraries over static libraries
+ in the load path
+
+ 8/11
+ ----
+support/shobj-conf
+ - new variable: SHLIB_LIBPREF, prefix for shared library name (defaults
+ to `lib'
+ - new variable: SHLIB_DLLVERSION, used on Cygwin to set the library
+ version number
+ - new variable: SHLIB_DOT, separator character between library name and
+ suffix and version information (defaults to `.')
+ - new stanza for cygwin to generate windows-compatible dll
+
+support/shlib-install
+ - add new option `-b bindir' for systems like cygwin/windows that
+ require it
+ - new stanza for cygwin that installs a dll into $bindir and an implied
+ link library into $libdir
+
+configure.in
+ - substitute new variables from shobj-conf
+
+shlib/Makefile.in
+ - substitute bindir, SHLIB_DOT, SHLIB_LIBPREF, SHLIB_DLLVERSION from
+ configure
+ - pass `-b $(bindir)' to shlib-install for install and uninstall targets
+ - library names now use $SHLIB_LIBPREF and $SHLIB_DOT
+
+INSTALL,README
+ - document new SHLIB_DOT, SHLIB_LIBPREF, and SHLIB_DLLVERSION variables
+
+ 10/4
+ ----
+[readline-5.1-beta1 frozen]
+
+ 12/1
+ ----
+configure.in
+ - changed release status to `release'
+
+[readline-5.1 frozen]
+
+ 12/9
+ ----
+[readline-5.1 released]
+
+ 12/14
+ -----
+examples/rlfe/Makefile.in
+ - add @LIBS@ to LIBS assignment to pick up extra libraries from
+ configure
+
+ 1/3/2006
+ --------
+support/shlib-install
+ - Install shared libraries with execute bit set on Linux
+
+ 6/9
+ ---
+[readline-5.2-alpha frozen]
+
+ 6/26
+ ----
+configure.in
+ - set CROSS_COMPILE to the empty string by default, so we don't inherit
+ a random value from the environment
+
+ 7/8
+ ---
+[readline-5.2-alpha released]
+
+
+[readline-5.2-beta released]
+
+ 9/12
+ ----
+config.h.in
+ - add defines for wcscoll, iswctype, iswupper, iswlower, towupper,
+ towlower functions
+ - replace define for wctomb with one for wcrtomb
+ - add defines for wchar_t, wint_t, wctype_t types
+
+ 10/11
+ -----
+[readline-5.2 released]
+
+ 11/9
+ ----
+examples/rlfe/{configure.in,Makefile.in,config.h.in,rlfe.c,pty.c}
+ - portability fixes from Mike Frysinger <vapier@gentoo.org>
+
+ 11/21
+ -----
+Makefile.in
+ - add `install-examples' and `uninstall-examples' targets
+
+examples/Makefile.in
+ - add correct variables to build examples on Windows
+ - add appropriate rules to install and uninstall example sources in
+ $(datadir)/readline
+
+ 11/27
+ -----
+config.h.in
+ - move #undef of HAVE_STRCOLL out of config.h.in, since autoconf tries
+ to substitute it based on configure tests
+
+ 4/27/2007
+ ---------
+examples/autoconf
+ - new directory with example autoconf macros to detect readline and
+ return information about the installed version
+
+ 6/13
+ ----
+support/shlib-install
+ - changes to support AIX 5.x shared library installation
+
+ 3/20/2008
+ ---------
+support/shlib-install
+ - add support for NetBSD and Interix shared library installation
+
+ 4/22
+ ----
+support/wcwidth.c
+ - updated implementation from 2007-05
+
+ 7/18
+ ----
+support/shlib-install
+ - support for mingw32, contributed by Carlo Bramix <carlo.bramix@libero.it>
+
+ 8/4
+ ---
+configure.in
+ - changed to readline-6.0
+
+ 8/18
+ ----
+support/config.{guess,sub}
+ - updated to newer versions from autoconf-2.62 distribution
diff --git a/CHANGES b/CHANGES
index f83201c..5d824a4 100644
--- a/CHANGES
+++ b/CHANGES
@@ -100,6 +100,8 @@ i. There is a new `revert-all-at-newline' variable. If enabled, readline will
undo all outstanding changes to all history lines when `accept-line' is
executed.
+j. If the kernel supports it, readline displays special characters
+ corresponding to a keyboard-generated signal when the signal is received.
-------------------------------------------------------------------------------
This document details the changes between this version, readline-5.2,
and the previous version, readline-5.1.
diff --git a/CHANGES~ b/CHANGES~
new file mode 100644
index 0000000..f83201c
--- /dev/null
+++ b/CHANGES~
@@ -0,0 +1,1098 @@
+This document details the changes between this version, readline-6.0,
+and the previous version, readline-5.2.
+
+1. Changes to Readline
+
+a. Fixed a number of redisplay errors in environments supporting multibyte
+ characters.
+
+b. Fixed bugs in vi command mode that caused motion commands to inappropriately
+ set the mark.
+
+c. When using the arrow keys in vi insertion mode, readline allows movement
+ beyond the current end of the line (unlike command mode).
+
+d. Fixed bugs that caused readline to loop when the terminal has been taken
+ away and reads return -1/EIO.
+
+e. Fixed bugs in redisplay occurring when displaying prompts containing
+ invisible characters.
+
+f. Fixed a bug that caused the completion append character to not be reset to
+ the default after an application-specified completion function changed it.
+
+g. Fixed a problem that caused incorrect positioning of the cursor while in
+ emacs editing mode when moving forward at the end of a line while using
+ a locale supporting multibyte characters.
+
+h. Fixed an off-by-one error that caused readline to drop every 511th
+ character of buffered input.
+
+i. Fixed a bug that resulted in SIGTERM not being caught or cleaned up.
+
+j. Fixed redisplay bugs caused by multiline prompts with invisible characters
+ or no characters following the final newline.
+
+k. Fixed redisplay bug caused by prompts consisting solely of invisible
+ characters.
+
+l. Fixed a bug in the code that buffers characters received very quickly in
+ succession which caused characters to be dropped.
+
+m. Fixed a bug that caused readline to reference uninitialized data structures
+ if it received a SIGWINCH before completing initialzation.
+
+n. Fixed a bug that caused the vi-mode `last command' to be set incorrectly
+ and therefore unrepeatable.
+
+o. Fixed a bug that caused readline to disable echoing when it was being used
+ with an output file descriptor that was not a terminal.
+
+p. Readline now blocks SIGINT while manipulating internal data structures
+ during redisplay.
+
+q. Fixed a bug in redisplay that caused readline to segfault when pasting a
+ very long line (over 130,000 characters).
+
+r. Fixed bugs in redisplay when using prompts with no visible printing
+ characters.
+
+s. Fixed a bug that caused redisplay errors when using prompts with invisible
+ characters and numeric arguments to a command in a multibyte locale.
+
+t. Fixed a bug that caused redisplay errors when using prompts with invisible
+ characters spanning more than two physical screen lines.
+
+2. New Features in Readline
+
+a. A new variable, rl_sort_completion_matches; allows applications to inhibit
+ match list sorting (but beware: some things don't work right if
+ applications do this).
+
+b. A new variable, rl_completion_invoking_key; allows applications to discover
+ the key that invoked rl_complete or rl_menu_complete.
+
+c. The functions rl_block_sigint and rl_release_sigint are now public and
+ available to calling applications who want to protect critical sections
+ (like redisplay).
+
+d. The functions rl_save_state and rl_restore_state are now public and
+ available to calling applications; documented rest of readline's state
+ flag values.
+
+e. A new user-settable variable, `history-size', allows setting the maximum
+ number of entries in the history list.
+
+f. There is a new implementation of menu completion, with several improvements
+ over the old; the most notable improvement is a better `completions
+ browsing' mode.
+
+g. The menu completion code now uses the rl_menu_completion_entry_function
+ variable, allowing applications to provide their own menu completion
+ generators.
+
+h. There is support for replacing a prefix of a pathname with a `...' when
+ displaying possible completions. This is controllable by setting the
+ `completion-prefix-display-length' variable. Matches with a common prefix
+ longer than this value have the common prefix replaced with `...'.
+
+i. There is a new `revert-all-at-newline' variable. If enabled, readline will
+ undo all outstanding changes to all history lines when `accept-line' is
+ executed.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-5.2,
+and the previous version, readline-5.1.
+
+1. Changes to Readline
+
+a. Fixed a problem that caused segmentation faults when using readline in
+ callback mode and typing consecutive DEL characters on an empty line.
+
+b. Fixed several redisplay problems with multibyte characters, all having to
+ do with the different code paths and variable meanings between single-byte
+ and multibyte character redisplay.
+
+c. Fixed a problem with key sequence translation when presented with the
+ sequence \M-\C-x.
+
+d. Fixed a problem that prevented the `a' command in vi mode from being
+ undone and redone properly.
+
+e. Fixed a problem that prevented empty inserts in vi mode from being undone
+ properly.
+
+f. Fixed a problem that caused readline to initialize with an incorrect idea
+ of whether or not the terminal can autowrap.
+
+g. Fixed output of key bindings (like bash `bind -p') to honor the setting of
+ convert-meta and use \e where appropriate.
+
+h. Changed the default filename completion function to call the filename
+ dequoting function if the directory completion hook isn't set. This means
+ that any directory completion hooks need to dequote the directory name,
+ since application-specific hooks need to know how the word was quoted,
+ even if no other changes are made.
+
+i. Fixed a bug with creating the prompt for a non-interactive search string
+ when there are non-printing characters in the primary prompt.
+
+j. Fixed a bug that caused prompts with invisible characters to be redrawn
+ multiple times in a multibyte locale.
+
+k. Fixed a bug that could cause the key sequence scanning code to return the
+ wrong function.
+
+l. Fixed a problem with the callback interface that caused it to fail when
+ using multi-character keyboard macros.
+
+m. Fixed a bug that could cause a core dump when an edited history entry was
+ re-executed under certain conditions.
+
+n. Fixed a bug that caused readline to reference freed memory when attmpting
+ to display a portion of the prompt.
+
+o. Fixed a bug with prompt redisplay in a multi-byte locale to avoid redrawing
+ the prompt and input line multiple times.
+
+p. Fixed history expansion to not be confused by here-string redirection.
+
+q. Readline no longer treats read errors by converting them to newlines, as
+ it does with EOF. This caused partial lines to be returned from readline().
+
+r. Fixed a redisplay bug that occurred in multibyte-capable locales when the
+ prompt was one character longer than the screen width.
+
+2. New Features in Readline
+
+a. Calling applications can now set the keyboard timeout to 0, allowing
+ poll-like behavior.
+
+b. The value of SYS_INPUTRC (configurable at compilation time) is now used as
+ the default last-ditch startup file.
+
+c. The history file reading functions now allow windows-like \r\n line
+ terminators.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-5.1,
+and the previous version, readline-5.0.
+
+1. Changes to Readline
+
+a. Fixed a bug that caused multiliine prompts to be wrapped and displayed
+ incorrectly.
+
+b. Fixed a bug that caused ^P/^N in emacs mode to fail to display the current
+ line correctly.
+
+c. Fixed a problem in computing the number of invisible characters on the first
+ line of a prompt whose length exceeds the screen width.
+
+d. Fixed vi-mode searching so that failure preserves the current line rather
+ than the last line in the history list.
+
+e. Fixed the vi-mode `~' command (change-case) to have the correct behavior at
+ end-of-line when manipulating multibyte characters.
+
+f. Fixed the vi-mode `r' command (change-char) to have the correct behavior at
+ end-of-line when manipulating multibyte characters.
+
+g. Fixed multiple bugs in the redisplay of multibyte characters: displaying
+ prompts longer than the screen width containing multibyte characters,
+
+h. Fix the calculation of the number of physical characters in the prompt
+ string when it contains multibyte characters.
+
+i. A non-zero value for the `rl_complete_suppress_append' variable now causes
+ no `/' to be appended to a directory name.
+
+j. Fixed forward-word and backward-word to work when words contained
+ multibyte characters.
+
+k. Fixed a bug in finding the delimiter of a `?' substring when performing
+ history expansion in a locale that supports multibyte characters.
+
+l. Fixed a memory leak caused by not freeing the timestamp in a history entry.
+
+m. Fixed a bug that caused "\M-x" style key bindings to not obey the setting
+ of the `convert-meta' variable.
+
+n. Fixed saving and restoring primary prompt when prompting for incremental
+ and non-incremental searches; search prompts now display multibyte
+ characters correctly.
+
+o. Fixed a bug that caused keys originally bound to self-insert but shadowed
+ by a multi-character key sequence to not be inserted.
+
+p. Fixed code so rl_prep_term_function and rl_deprep_term_function aren't
+ dereferenced if NULL (matching the documentation).
+
+q. Extensive changes to readline to add enough state so that commands
+ requiring additional characters (searches, multi-key sequences, numeric
+ arguments, commands requiring an additional specifier character like
+ vi-mode change-char, etc.) work without synchronously waiting for
+ additional input.
+
+r. Lots of changes so readline builds and runs on MinGW.
+
+s. Readline no longer tries to modify the terminal settings when running in
+ callback mode.
+
+t. The Readline display code no longer sets the location of the last invisible
+ character in the prompt if the \[\] sequence is empty.
+
+u. The `change-case' command now correctly changes the case of multibyte
+ characters.
+
+v. Changes to the shared library construction scripts to deal with Windows
+ DLL naming conventions for Cygwin.
+
+w. Fixed the redisplay code to avoid core dumps resulting from a poorly-timed
+ SIGWINCH.
+
+x. Fixed the non-incremental search code in vi mode to dispose of any current
+ undo list when copying a line from the history into the current editing
+ buffer.
+
+y. Fixed a bug that caused reversing the incremental search direction to
+ not work correctly.
+
+z. Fixed the vi-mode `U' command to only undo up to the first time insert mode
+ was entered, as Posix specifies.
+
+aa. Fixed a bug in the vi-mode `r' command that left the cursor in the wrong
+ place.
+
+bb. Fixed a redisplay bug caused by moving the cursor vertically to a line
+ with invisible characters in the prompt in a multibyte locale.
+
+cc. Fixed a bug that could cause the terminal special chars to be bound in the
+ wrong keymap in vi mode.
+
+2. New Features in Readline
+
+a. The key sequence sent by the keypad `delete' key is now automatically
+ bound to delete-char.
+
+b. A negative argument to menu-complete now cycles backward through the
+ completion list.
+
+c. A new bindable readline variable: bind-tty-special-chars. If non-zero,
+ readline will bind the terminal special characters to their readline
+ equivalents when it's called (on by default).
+
+d. New bindable command: vi-rubout. Saves deleted text for possible
+ reinsertion, as with any vi-mode `text modification' command; `X' is bound
+ to this in vi command mode.
+
+e. If the rl_completion_query_items is set to a value < 0, readline never
+ asks the user whether or not to view the possible completions.
+
+f. The `C-w' binding in incremental search now understands multibyte
+ characters.
+
+g. New application-callable auxiliary function, rl_variable_value, returns
+ a string corresponding to a readline variable's value.
+
+h. When parsing inputrc files and variable binding commands, the parser
+ strips trailing whitespace from values assigned to boolean variables
+ before checking them.
+
+i. A new external application-controllable variable that allows the LINES
+ and COLUMNS environment variables to set the window size regardless of
+ what the kernel returns.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-5.0,
+and the previous version, readline-4.3.
+
+1. Changes to Readline
+
+a. Fixes to avoid core dumps because of null pointer references in the
+ multibyte character code.
+
+b. Fix to avoid infinite recursion caused by certain key combinations.
+
+c. Fixed a bug that caused the vi-mode `last command' to be set incorrectly.
+
+d. Readline no longer tries to read ahead more than one line of input, even
+ when more is available.
+
+e. Fixed the code that adjusts the point to not mishandle null wide
+ characters.
+
+f. Fixed a bug in the history expansion `g' modifier that caused it to skip
+ every other match.
+
+g. Fixed a bug that caused the prompt to overwrite previous output when the
+ output doesn't contain a newline and the locale supports multibyte
+ characters. This same change fixes the problem of readline redisplay
+ slowing down dramatically as the line gets longer in multibyte locales.
+
+h. History traversal with arrow keys in vi insertion mode causes the cursor
+ to be placed at the end of the new line, like in emacs mode.
+
+i. The locale initialization code does a better job of using the right
+ precedence and defaulting when checking the appropriate environment
+ variables.
+
+j. Fixed the history word tokenizer to handle <( and >( better when used as
+ part of bash.
+
+k. The overwrite mode code received several bug fixes to improve undo.
+
+l. Many speedups to the multibyte character redisplay code.
+
+m. The callback character reading interface should not hang waiting to read
+ keyboard input.
+
+n. Fixed a bug with redoing vi-mode `s' command.
+
+o. The code that initializes the terminal tracks changes made to the terminal
+ special characters with stty(1) (or equivalent), so that these changes
+ are reflected in the readline bindings. New application-callable function
+ to make it work: rl_tty_unset_default_bindings().
+
+p. Fixed a bug that could cause garbage to be inserted in the buffer when
+ changing character case in vi mode when using a multibyte locale.
+
+q. Fixed a bug in the redisplay code that caused problems on systems
+ supporting multibyte characters when moving between history lines when the
+ new line has more glyphs but fewer bytes.
+
+r. Undo and redo now work better after exiting vi insertion mode.
+
+s. Make sure system calls are restarted after a SIGWINCH is received using
+ SA_RESTART.
+
+t. Improvements to the code that displays possible completions when using
+ multibyte characters.
+
+u. Fixed a problem when parsing nested if statements in inputrc files.
+
+v. The completer now takes multibyte characters into account when looking for
+ quoted substrings on which to perform completion.
+
+w. The history search functions now perform better bounds checking on the
+ history list.
+
+x. Change to history expansion functions to treat `^' as equivalent to word
+ one, as the documention states.
+
+y. Some changes to the display code to improve display and redisplay of
+ multibyte characters.
+
+z. Changes to speed up the multibyte character redisplay code.
+
+aa. Fixed a bug in the vi-mode `E' command that caused it to skip over the
+ last character of a word if invoked while point was on the word's
+ next-to-last character.
+
+bb. Fixed a bug that could cause incorrect filename quoting when
+ case-insensitive completion was enabled and the word being completed
+ contained backslashes quoting word break characters.
+
+cc. Fixed a bug in redisplay triggered when the prompt string contains
+ invisible characters.
+
+dd. Fixed some display (and other) bugs encountered in multibyte locales
+ when a non-ascii character was the last character on a line.
+
+ee. Fixed some display bugs caused by multibyte characters in prompt strings.
+
+ff. Fixed a problem with history expansion caused by non-whitespace characters
+ used as history word delimiters.
+
+gg. Fixed a problem that could cause readline to refer to freed memory when
+ moving between history lines while doing searches.
+
+hh. Improvements to the code that expands and displays prompt strings
+ containing multibyte characters.
+
+ii. Fixed a problem with vi-mode not correctly remembering the numeric argument
+ to the last `c'hange command for later use with `.'.
+
+jj. Fixed a bug in vi-mode that caused multi-digit count arguments to work
+ incorrectly.
+
+kk. Fixed a problem in vi-mode that caused the last text modification command
+ to not be remembered across different command lines.
+
+ll. Fixed problems with changing characters and changing case at the end of
+ the line.
+
+mm. Fixed a problem with readline saving the contents of the current line
+ before beginning a non-interactive search.
+
+nn. Fixed a problem with EOF detection when using rl_event_hook.
+
+oo. Fixed a problem with the vi mode `p' and `P' commands ignoring numeric
+ arguments.
+
+2. New Features in Readline
+
+a. History expansion has a new `a' modifier equivalent to the `g' modifier
+ for compatibility with the BSD csh.
+
+b. History expansion has a new `G' modifier equivalent to the BSD csh `g'
+ modifier, which performs a substitution once per word.
+
+c. All non-incremental search operations may now undo the operation of
+ replacing the current line with the history line.
+
+d. The text inserted by an `a' command in vi mode can be reinserted with
+ `.'.
+
+e. New bindable variable, `show-all-if-unmodified'. If set, the readline
+ completer will list possible completions immediately if there is more
+ than one completion and partial completion cannot be performed.
+
+f. There is a new application-callable `free_history_entry()' function.
+
+g. History list entries now contain timestamp information; the history file
+ functions know how to read and write timestamp information associated
+ with each entry.
+
+h. Four new key binding functions have been added:
+
+ rl_bind_key_if_unbound()
+ rl_bind_key_if_unbound_in_map()
+ rl_bind_keyseq_if_unbound()
+ rl_bind_keyseq_if_unbound_in_map()
+
+i. New application variable, rl_completion_quote_character, set to any
+ quote character readline finds before it calls the application completion
+ function.
+
+j. New application variable, rl_completion_suppress_quote, settable by an
+ application completion function. If set to non-zero, readline does not
+ attempt to append a closing quote to a completed word.
+
+k. New application variable, rl_completion_found_quote, set to a non-zero
+ value if readline determines that the word to be completed is quoted.
+ Set before readline calls any application completion function.
+
+l. New function hook, rl_completion_word_break_hook, called when readline
+ needs to break a line into words when completion is attempted. Allows
+ the word break characters to vary based on position in the line.
+
+m. New bindable command: unix-filename-rubout. Does the same thing as
+ unix-word-rubout, but adds `/' to the set of word delimiters.
+
+n. When listing completions, directories have a `/' appended if the
+ `mark-directories' option has been enabled.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-4.3,
+and the previous version, readline-4.2a.
+
+1. Changes to Readline
+
+a. Fixed output of comment-begin character when listing variable values.
+
+b. Added some default key bindings for common escape sequences produced by
+ HOME and END keys.
+
+c. Fixed the mark handling code to be more emacs-compatible.
+
+d. A bug was fixed in the code that prints possible completions to keep it
+ from printing empty strings in certain circumstances.
+
+e. Change the key sequence printing code to print ESC as M\- if ESC is a
+ meta-prefix character -- it's easier for users to understand than \e.
+
+f. Fixed unstifle_history() to return values that match the documentation.
+
+g. Fixed the event loop (rl_event_hook) to handle the case where the input
+ file descriptor is invalidated.
+
+h. Fixed the prompt display code to work better when the application has a
+ custom redisplay function.
+
+i. Changes to make reading and writing the history file a little faster, and
+ to cope with huge history files without calling abort(3) from xmalloc.
+
+j. The vi-mode `S' and `s' commands are now undone correctly.
+
+k. Fixed a problem which caused the display to be messed up when the last
+ line of a multi-line prompt (possibly containing invisible characters)
+ was longer than the screen width.
+
+2. New Features in Readline
+
+a. Support for key `subsequences': allows, e.g., ESC and ESC-a to both
+ be bound to readline functions. Now the arrow keys may be used in vi
+ insert mode.
+
+b. When listing completions, and the number of lines displayed is more than
+ the screen length, readline uses an internal pager to display the results.
+ This is controlled by the `page-completions' variable (default on).
+
+c. New code to handle editing and displaying multibyte characters.
+
+d. The behavior introduced in bash-2.05a of deciding whether or not to
+ append a slash to a completed name that is a symlink to a directory has
+ been made optional, controlled by the `mark-symlinked-directories'
+ variable (default is the 2.05a behavior).
+
+e. The `insert-comment' command now acts as a toggle if given a numeric
+ argument: if the first characters on the line don't specify a
+ comment, insert one; if they do, delete the comment text
+
+f. New application-settable completion variable:
+ rl_completion_mark_symlink_dirs, allows an application's completion
+ function to temporarily override the user's preference for appending
+ slashes to names which are symlinks to directories.
+
+g. New function available to application completion functions:
+ rl_completion_mode, to tell how the completion function was invoked
+ and decide which argument to supply to rl_complete_internal (to list
+ completions, etc.).
+
+h. Readline now has an overwrite mode, toggled by the `overwrite-mode'
+ bindable command, which could be bound to `Insert'.
+
+i. New application-settable completion variable:
+ rl_completion_suppress_append, inhibits appending of
+ rl_completion_append_character to completed words.
+
+j. New key bindings when reading an incremental search string: ^W yanks
+ the currently-matched word out of the current line into the search
+ string; ^Y yanks the rest of the current line into the search string,
+ DEL or ^H deletes characters from the search string.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-4.2a,
+and the previous version, readline-4.2.
+
+1. Changes to Readline
+
+a. More `const' and type casting fixes.
+
+b. Changed rl_message() to use vsnprintf(3) (if available) to fix buffer
+ overflow problems.
+
+c. The completion code no longer appends a `/' or ` ' to a match when
+ completing a symbolic link that resolves to a directory name, unless
+ the match does not add anything to the word being completed. This
+ means that a tab will complete the word up to the full name, but not
+ add anything, and a subsequent tab will add a slash.
+
+d. Fixed a trivial typo that made the vi-mode `dT' command not work.
+
+e. Fixed the tty code so that ^S and ^Q can be inserted with rl_quoted_insert.
+
+f. Fixed the tty code so that ^V works more than once.
+
+g. Changed the use of __P((...)) for function prototypes to PARAMS((...))
+ because the use of __P in typedefs conflicted g++ and glibc.
+
+h. The completion code now attempts to do a better job of preserving the
+ case of the word the user typed if ignoring case in completions.
+
+i. Readline defaults to not echoing the input and lets the terminal
+ initialization code enable echoing if there is a controlling terminal.
+
+j. The key binding code now processes only two hex digits after a `\x'
+ escape sequence, and the documentation was changed to note that the
+ octal and hex escape sequences result in an eight-bit value rather
+ than strict ASCII.
+
+k. Fixed a few places where negative array subscripts could have occurred.
+
+l. Fixed the vi-mode code to use a better method to determine the bounds of
+ the array used to hold the marks, and to avoid out-of-bounds references.
+
+m. Fixed the defines in chardefs.h to work better when chars are signed.
+
+n. Fixed configure.in to use the new names for bash autoconf macros.
+
+o. Readline no longer attempts to define its own versions of some ctype
+ macros if they are implemented as functions in libc but not as macros in
+ <ctype.h>.
+
+p. Fixed a problem where rl_backward could possibly set point to before
+ the beginning of the line.
+
+q. Fixed Makefile to not put -I/usr/include into CFLAGS, since it can cause
+ include file problems.
+
+2. New Features in Readline
+
+a. Added extern declaration for rl_get_termcap to readline.h, making it a
+ public function (it was always there, just not in readline.h).
+
+b. New #defines in readline.h: RL_READLINE_VERSION, currently 0x0402,
+ RL_VERSION_MAJOR, currently 4, and RL_VERSION_MINOR, currently 2.
+
+c. New readline variable: rl_readline_version, mirrors RL_READLINE_VERSION.
+
+d. New bindable boolean readline variable: match-hidden-files. Controls
+ completion of files beginning with a `.' (on Unix). Enabled by default.
+
+e. The history expansion code now allows any character to terminate a
+ `:first-' modifier, like csh.
+
+f. The incremental search code remembers the last search string and uses
+ it if ^R^R is typed without a search string.
+
+h. New bindable variable `history-preserve-point'. If set, the history
+ code attempts to place the user at the same location on each history
+ line retrived with previous-history or next-history.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-4.2,
+and the previous version, readline-4.1.
+
+1. Changes to Readline
+
+a. When setting the terminal attributes on systems using `struct termio',
+ readline waits for output to drain before changing the attributes.
+
+b. A fix was made to the history word tokenization code to avoid attempts to
+ dereference a null pointer.
+
+c. Readline now defaults rl_terminal_name to $TERM if the calling application
+ has left it unset, and tries to initialize with the resultant value.
+
+d. Instead of calling (*rl_getc_function)() directly to get input in certain
+ places, readline now calls rl_read_key() consistently.
+
+e. Fixed a bug in the completion code that allowed a backslash to quote a
+ single quote inside a single-quoted string.
+
+f. rl_prompt is no longer assigned directly from the argument to readline(),
+ but uses memory allocated by readline. This allows constant strings to
+ be passed to readline without problems arising when the prompt processing
+ code wants to modify the string.
+
+g. Fixed a bug that caused non-interactive history searches to return the
+ wrong line when performing multiple searches backward for the same string.
+
+h. Many variables, function arguments, and function return values are now
+ declared `const' where appropriate, to improve behavior when linking with
+ C++ code.
+
+i. The control character detection code now works better on systems where
+ `char' is unsigned by default.
+
+j. The vi-mode numeric argument is now capped at 999999, just like emacs mode.
+
+k. The Function, CPFunction, CPPFunction, and VFunction typedefs have been
+ replaced with a set of specific prototyped typedefs, though they are
+ still in the readline header files for backwards compatibility.
+
+m. Nearly all of the (undocumented) internal global variables in the library
+ now have an _rl_ prefix -- there were a number that did not, like
+ screenheight, screenwidth, alphabetic, etc.
+
+n. The ding() convenience function has been renamed to rl_ding(), though the
+ old function is still defined for backwards compatibility.
+
+o. The completion convenience functions filename_completion_function,
+ username_completion_function, and completion_matches now have an rl_
+ prefix, though the old names are still defined for backwards compatibility.
+
+p. The functions shared by readline and bash (linkage is satisfied from bash
+ when compiling with bash, and internally otherwise) now have an sh_ prefix.
+
+q. Changed the shared library creation procedure on Linux and BSD/OS 4.x so
+ that the `soname' contains only the major version number rather than the
+ major and minor numbers.
+
+r. Fixed a redisplay bug that occurred when the prompt spanned more than one
+ physical line and contained invisible characters.
+
+s. Added a missing `includedir' variable to the Makefile.
+
+t. When installing the shared libraries, make sure symbolic links are relative.
+
+u. Added configure test so that it can set `${MAKE}' appropriately.
+
+v. Fixed a bug in rl_forward that could cause the point to be set to before
+ the beginning of the line in vi mode.
+
+w. Fixed a bug in the callback read-char interface to make it work when a
+ readline function pushes some input onto the input stream with
+ rl_execute_next (like the incremental search functions).
+
+x. Fixed a file descriptor leak in the history file manipulation code that
+ was tripped when attempting to truncate a non-regular file (like
+ /dev/null).
+
+y. Changes to make all of the exported readline functions declared in
+ readline.h have an rl_ prefix (rltty_set_default_bindings is now
+ rl_tty_set_default_bindings, crlf is now rl_crlf, etc.)
+
+z. The formatted documentation included in the base readline distribution
+ is no longer removed on a `make distclean'.
+
+aa. Some changes were made to avoid gcc warnings with -Wall.
+
+bb. rl_get_keymap_by_name now finds keymaps case-insensitively, so
+ `set keymap EMACS' works.
+
+cc. The history file writing and truncation functions now return a useful
+ status on error.
+
+dd. Fixed a bug that could cause applications to dereference a NULL pointer
+ if a NULL second argument was passed to history_expand().
+
+ee. If a hook function assigned to rl_event_hook sets rl_done to a non-zero
+ value, rl_read_key() now immediately returns '\n' (which is assumed to
+ be bound to accept-line).
+
+2. New Features in Readline
+
+a. The blink timeout for paren matching is now settable by applications,
+ via the rl_set_paren_blink_timeout() function.
+
+b. _rl_executing_macro has been renamed to rl_executing_macro, which means
+ it's now part of the public interface.
+
+c. Readline has a new variable, rl_readline_state, which is a bitmap that
+ encapsulates the current state of the library; intended for use by
+ callbacks and hook functions.
+
+d. rlfe has a new -l option to log input and output (-a appends to logfile),
+ a new -n option to set the readline application name, and -v and -h
+ options for version and help information.
+
+e. rlfe can now perform filename completion for the inferior process if the
+ OS has a /proc/<PID>/cwd that can be read with readlink(2) to get the
+ inferior's current working directory.
+
+f. A new file, rltypedefs.h, contains the new typedefs for function pointers
+ and is installed by `make install'.
+
+g. New application-callable function rl_set_prompt(const char *prompt):
+ expands its prompt string argument and sets rl_prompt to the result.
+
+h. New application-callable function rl_set_screen_size(int rows, int cols):
+ public method for applications to set readline's idea of the screen
+ dimensions.
+
+i. The history example program (examples/histexamp.c) is now built as one
+ of the examples.
+
+j. The documentation has been updated to cover nearly all of the public
+ functions and variables declared in readline.h.
+
+k. New function, rl_get_screen_size (int *rows, int *columns), returns
+ readline's idea of the screen dimensions.
+
+l. The timeout in rl_gather_tyi (readline keyboard input polling function)
+ is now settable via a function (rl_set_keyboard_input_timeout()).
+
+m. Renamed the max_input_history variable to history_max_entries; the old
+ variable is maintained for backwards compatibility.
+
+n. The list of characters that separate words for the history tokenizer is
+ now settable with a variable: history_word_delimiters. The default
+ value is as before.
+
+o. There is a new history.3 manual page documenting the history library.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-4.1,
+and the previous version, readline-4.0.
+
+1. Changes to Readline
+
+a. Changed the HTML documents so that the table-of-contents is no longer
+ a separate file.
+
+b. Changes to the shared object configuration for: Irix 5.x, Irix 6.x,
+ OSF/1.
+
+c. The shared library major and minor versions are now constructed
+ automatically by configure and substituted into the makefiles.
+
+d. It's now possible to install the shared libraries separately from the
+ static libraries.
+
+e. The history library tries to truncate the history file only if it is a
+ regular file.
+
+f. A bug that caused _rl_dispatch to address negative array indices on
+ systems with signed chars was fixed.
+
+g. rl-yank-nth-arg now leaves the history position the same as when it was
+ called.
+
+h. Changes to the completion code to handle MS-DOS drive-letter:pathname
+ filenames.
+
+i. Completion is now case-insensitive by default on MS-DOS.
+
+j. Fixes to the history file manipulation code for MS-DOS.
+
+k. Readline attempts to bind the arrow keys to appropriate defaults on MS-DOS.
+
+l. Some fixes were made to the redisplay code for better operation on MS-DOS.
+
+m. The quoted-insert code will now insert tty special chars like ^C.
+
+n. A bug was fixed that caused the display code to reference memory before
+ the start of the prompt string.
+
+o. More support for __EMX__ (OS/2).
+
+p. A bug was fixed in readline's signal handling that could cause infinite
+ recursion in signal handlers.
+
+q. A bug was fixed that caused the point to be less than zero when rl_forward
+ was given a very large numeric argument.
+
+r. The vi-mode code now gets characters via the application-settable value
+ of rl_getc_function rather than calling rl_getc directly.
+
+s. The history file code now uses O_BINARY mode when reading and writing
+ the history file on cygwin32.
+
+t. Fixed a bug in the redisplay code for lines with more than 256 line
+ breaks.
+
+u. A bug was fixed which caused invisible character markers to not be
+ stripped from the prompt string if the terminal was in no-echo mode.
+
+v. Readline no longer tries to get the variables it needs for redisplay
+ from the termcap entry if the calling application has specified its
+ own redisplay function. Readline treats the terminal as `dumb' in
+ this case.
+
+w. Fixes to the SIGWINCH code so that a multiple-line prompt with escape
+ sequences is redrawn correctly.
+
+x. Changes to the install and install-shared targets so that the libraries
+ and header files are installed separately.
+
+2. New Features in Readline
+
+a. A new Readline `user manual' is in doc/rluserman.texinfo.
+
+b. Parentheses matching is now always compiled into readline, and enabled
+ or disabled when the value of the `blink-matching-paren' variable is
+ changed.
+
+c. MS-DOS systems now use ~/_inputrc as the last-ditch inputrc filename.
+
+d. MS-DOS systems now use ~/_history as the default history file.
+
+e. history-search-{forward,backward} now leave the point at the end of the
+ line when the string to search for is empty, like
+ {reverse,forward}-search-history.
+
+f. history-search-{forward,backward} now leave the last history line found
+ in the readline buffer if the second or subsequent search fails.
+
+g. New function for use by applications: rl_on_new_line_with_prompt, used
+ when an application displays the prompt itself before calling readline().
+
+h. New variable for use by applications: rl_already_prompted. An application
+ that displays the prompt itself before calling readline() must set this to
+ a non-zero value.
+
+i. A new variable, rl_gnu_readline_p, always 1. The intent is that an
+ application can verify whether or not it is linked with the `real'
+ readline library or some substitute.
+
+j. Per Bothner's `rlfe' (pronounced `Ralphie') readline front-end program
+ is included in the examples subdirectory, though it is not built
+ by default.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-4.0,
+and the previous version, readline-2.2.
+
+1. Changes to Readline
+
+a. The version number is now 4.0, to match the major and minor version
+ numbers on the shared readline and history libraries. Future
+ releases will maintain the identical numbering.
+
+b. Fixed a typo in the `make install' recipe that copied libreadline.a
+ to libhistory.old right after installing it.
+
+c. The readline and history info files are now installed out of the source
+ directory if they are not found in the build directory.
+
+d. The library no longer exports a function named `savestring' -- backwards
+ compatibility be damned.
+
+e. There is no longer any #ifdef SHELL code in the source files.
+
+f. Some changes were made to the key binding code to fix memory leaks and
+ better support Win32 systems.
+
+g. Fixed a silly typo in the paren matching code -- it's microseconds, not
+ milliseconds.
+
+h. The readline library should be compilable by C++ compilers.
+
+i. The readline.h public header file now includes function prototypes for
+ all readline functions, and some changes were made to fix errors in the
+ source files uncovered by the use of prototypes.
+
+j. The maximum numeric argument is now clamped at 1000000.
+
+k. Fixes to rl_yank_last_arg to make it behave better.
+
+l. Fixed a bug in the display code that caused core dumps if the prompt
+ string length exceeded 1024 characters.
+
+m. The menu completion code was fixed to properly insert a single completion
+ if there is only one match.
+
+n. A bug was fixed that caused the display code to improperly display tabs
+ after newlines.
+
+o. A fix was made to the completion code in which a typo caused the wrong
+ value to be passed to the function that computed the longest common
+ prefix of the list of matches.
+
+p. The completion code now checks the value of rl_filename_completion_desired,
+ which is set by application-supplied completion functions to indicate
+ that filename completion is being performed, to decide whether or not to
+ call an application-supplied `ignore completions' function.
+
+q. Code was added to the history library to catch history substitutions
+ using `&' without a previous history substitution or search having been
+ performed.
+
+
+2. New Features in Readline
+
+a. There is a new script, support/shobj-conf, to do system-specific shared
+ object and library configuration. It generates variables for configure
+ to substitute into makefiles. The README file provides a detailed
+ explanation of the shared library creation process.
+
+b. Shared libraries and objects are now built in the `shlib' subdirectory.
+ There is a shlib/Makefile.in to control the build process. `make shared'
+ from the top-level directory is still the right way to build shared
+ versions of the libraries.
+
+c. rlconf.h is now installed, so applications can find out which features
+ have been compiled into the installed readline and history libraries.
+
+d. rlstdc.h is now an installed header file.
+
+e. Many changes to the signal handling:
+ o Readline now catches SIGQUIT and cleans up the tty before returning;
+ o A new variable, rl_catch_signals, is available to application writers
+ to indicate to readline whether or not it should install its own
+ signal handlers for SIGINT, SIGTERM, SIGQUIT, SIGALRM, SIGTSTP,
+ SIGTTIN, and SIGTTOU;
+ o A new variable, rl_catch_sigwinch, is available to application
+ writers to indicate to readline whether or not it should install its
+ own signal handler for SIGWINCH, which will chain to the calling
+ applications's SIGWINCH handler, if one is installed;
+ o There is a new function, rl_free_line_state, for application signal
+ handlers to call to free up the state associated with the current
+ line after receiving a signal;
+ o There is a new function, rl_cleanup_after_signal, to clean up the
+ display and terminal state after receiving a signal;
+ o There is a new function, rl_reset_after_signal, to reinitialize the
+ terminal and display state after an application signal handler
+ returns and readline continues
+
+f. There is a new function, rl_resize_terminal, to reset readline's idea of
+ the screen size after a SIGWINCH.
+
+g. New public functions: rl_save_prompt and rl_restore_prompt. These were
+ previously private functions with a `_' prefix. These functions are
+ used when an application wants to write a message to the `message area'
+ with rl_message and have the prompt restored correctly when the message
+ is erased.
+
+h. New function hook: rl_pre_input_hook, called just before readline starts
+ reading input, after initialization.
+
+i. New function hook: rl_display_matches_hook, called when readline would
+ display the list of completion matches. The new function
+ rl_display_match_list is what readline uses internally, and is available
+ for use by application functions called via this hook.
+
+j. New bindable function, delete-char-or-list, like tcsh.
+
+k. A new variable, rl_erase_empty_line, which, if set by an application using
+ readline, will cause readline to erase, prompt and all, lines on which the
+ only thing typed was a newline.
+
+l. There is a new script, support/shlib-install, to install and uninstall
+ the shared readline and history libraries.
+
+m. A new bindable variable, `isearch-terminators', which is a string
+ containing the set of characters that should terminate an incremental
+ search without being executed as a command.
+
+n. A new bindable function, forward-backward-delete-char.
+
+-------------------------------------------------------------------------------
+This document details the changes between this version, readline-2.2,
+and the previous version, readline-2.1.
+
+1. Changes to Readline
+
+a. Added a missing `extern' to a declaration in readline.h that kept
+ readline from compiling cleanly on some systems.
+
+b. The history file is now opened with mode 0600 when it is written for
+ better security.
+
+c. Changes were made to the SIGWINCH handling code so that prompt redisplay
+ is done better.
+
+d. ^G now interrupts incremental searches correctly.
+
+e. A bug that caused a core dump when the set of characters to be quoted
+ when completing words was empty was fixed.
+
+f. Fixed a problem in the readline test program rltest.c that caused a core
+ dump.
+
+g. The code that handles parser directives in inputrc files now displays
+ more error messages.
+
+h. The history expansion code was fixed so that the appearance of the
+ history comment character at the beginning of a word inhibits history
+ expansion for that word and the rest of the input line.
+
+i. The code that prints completion listings now behaves better if one or
+ more of the filenames contains non-printable characters.
+
+j. The time delay when showing matching parentheses is now 0.5 seconds.
+
+
+2. New Features in Readline
+
+a. There is now an option for `iterative' yank-last-arg handline, so a user
+ can keep entering `M-.', yanking the last argument of successive history
+ lines.
+
+b. New variable, `print-completions-horizontally', which causes completion
+ matches to be displayed across the screen (like `ls -x') rather than up
+ and down the screen (like `ls').
+
+c. New variable, `completion-ignore-case', which causes filename completion
+ and matching to be performed case-insensitively.
+
+d. There is a new bindable command, `magic-space', which causes history
+ expansion to be performed on the current readline buffer and a space to
+ be inserted into the result.
+
+e. There is a new bindable command, `menu-complete', which enables tcsh-like
+ menu completion (successive executions of menu-complete insert a single
+ completion match, cycling through the list of possible completions).
+
+f. There is a new bindable command, `paste-from-clipboard', for use on Win32
+ systems, to insert the text from the Win32 clipboard into the editing
+ buffer.
+
+g. The key sequence translation code now understands printf-style backslash
+ escape sequences, including \NNN octal escapes. These escape sequences
+ may be used in key sequence definitions or macro values.
+
+h. An `$include' inputrc file parser directive has been added.
diff --git a/NEWS b/NEWS
index a14e74e..8e30a35 100644
--- a/NEWS
+++ b/NEWS
@@ -37,3 +37,6 @@ h. There is support for replacing a prefix of a pathname with a `...' when
i. There is a new `revert-all-at-newline' variable. If enabled, readline will
undo all outstanding changes to all history lines when `accept-line' is
executed.
+
+j. If the kernel supports it, readline displays special characters
+ corresponding to a keyboard-generated signal when the signal is received.
diff --git a/NEWS~ b/NEWS~
new file mode 100644
index 0000000..a14e74e
--- /dev/null
+++ b/NEWS~
@@ -0,0 +1,39 @@
+This is a terse description of the new features added to readline-6.0 since
+the release of readline-5.2.
+
+1. New Features in Readline
+
+a. A new variable, rl_sort_completion_matches; allows applications to inhibit
+ match list sorting (but beware: some things don't work right if
+ applications do this).
+
+b. A new variable, rl_completion_invoking_key; allows applications to discover
+ the key that invoked rl_complete or rl_menu_complete.
+
+c. The functions rl_block_sigint and rl_release_sigint are now public and
+ available to calling applications who want to protect critical sections
+ (like redisplay).
+
+d. The functions rl_save_state and rl_restore_state are now public and
+ available to calling applications; documented rest of readline's state
+ flag values.
+
+e. A new user-settable variable, `history-size', allows setting the maximum
+ number of entries in the history list.
+
+f. There is a new implementation of menu completion, with several improvements
+ over the old; the most notable improvement is a better `completions
+ browsing' mode.
+
+g. The menu completion code now uses the rl_menu_completion_entry_function
+ variable, allowing applications to provide their own menu completion
+ generators.
+
+h. There is support for replacing a prefix of a pathname with a `...' when
+ displaying possible completions. This is controllable by setting the
+ `completion-prefix-display-length' variable. Matches with a common prefix
+ longer than this value have the common prefix replaced with `...'.
+
+i. There is a new `revert-all-at-newline' variable. If enabled, readline will
+ undo all outstanding changes to all history lines when `accept-line' is
+ executed.
diff --git a/complete.c b/complete.c
index 20bb1ea..59b486a 100644
--- a/complete.c
+++ b/complete.c
@@ -2208,7 +2208,7 @@ rl_old_menu_complete (count, invoking_key)
/* The first time through, we generate the list of matches and set things
up to insert them. */
- if (rl_last_func != rl_menu_complete)
+ if (rl_last_func != rl_old_menu_complete)
{
/* Clean up from previous call, if any. */
FREE (orig_text);
@@ -2220,6 +2220,8 @@ rl_old_menu_complete (count, invoking_key)
rl_completion_invoking_key = invoking_key;
+ RL_SETSTATE(RL_STATE_COMPLETING);
+
/* Only the completion entry function can change these. */
set_completion_defaults ('%');
@@ -2259,9 +2261,12 @@ rl_old_menu_complete (count, invoking_key)
FREE (orig_text);
orig_text = (char *)0;
completion_changed_buffer = 0;
+ RL_UNSETSTATE(RL_STATE_COMPLETING);
return (0);
}
+ RL_UNSETSTATE(RL_STATE_COMPLETING);
+
for (match_list_size = 0; matches[match_list_size]; match_list_size++)
;
/* matches[0] is lcd if match_list_size > 1, but the circular buffer
@@ -2337,6 +2342,8 @@ rl_menu_complete (count, ignore)
full_completion = 0;
+ RL_SETSTATE(RL_STATE_COMPLETING);
+
/* Only the completion entry function can change these. */
set_completion_defaults ('%');
@@ -2378,9 +2385,12 @@ rl_menu_complete (count, ignore)
FREE (orig_text);
orig_text = (char *)0;
completion_changed_buffer = 0;
+ RL_UNSETSTATE(RL_STATE_COMPLETING);
return (0);
}
+ RL_UNSETSTATE(RL_STATE_COMPLETING);
+
for (match_list_size = 0; matches[match_list_size]; match_list_size++)
;
diff --git a/display.c b/display.c
index e941c78..c58d4f7 100644
--- a/display.c
+++ b/display.c
@@ -512,6 +512,7 @@ rl_redisplay ()
/* Block keyboard interrupts because this function manipulates global
data structures. */
_rl_block_sigint ();
+ RL_SETSTATE (RL_STATE_REDISPLAYING);
if (!rl_display_prompt)
rl_display_prompt = "";
@@ -1188,9 +1189,11 @@ rl_redisplay ()
if (t < out)
line[t - 1] = '>';
- if (!rl_display_fixed || forced_display || lmargin != last_lmargin)
+ if (rl_display_fixed == 0 || forced_display || lmargin != last_lmargin)
{
forced_display = 0;
+ o_cpos = _rl_last_c_pos;
+ cpos_adjusted = 0;
update_line (&visible_line[last_lmargin],
&invisible_line[lmargin],
0,
@@ -1198,6 +1201,13 @@ rl_redisplay ()
_rl_screenwidth + (lmargin ? 0 : wrap_offset),
0);
+ if ((MB_CUR_MAX > 1 && rl_byte_oriented == 0) &&
+ cpos_adjusted == 0 &&
+ _rl_last_c_pos != o_cpos &&
+ _rl_last_c_pos > wrap_offset &&
+ o_cpos < prompt_last_invisible)
+ _rl_last_c_pos -= prompt_invis_chars_first_line; /* XXX - was wrap_offset */
+
/* If the visible new line is shorter than the old, but the number
of invisible characters is greater, and we are at the end of
the new line, we need to clear to eol. */
@@ -1236,6 +1246,7 @@ rl_redisplay ()
visible_wrap_offset = wrap_offset;
}
+ RL_UNSETSTATE (RL_STATE_REDISPLAYING);
_rl_release_sigint ();
}
@@ -1772,7 +1783,7 @@ update_line (old, new, current_line, omax, nmax, inv_botlin)
space_to_eol will insert too many spaces. XXX - maybe we should
adjust col_lendiff based on the difference between _rl_last_c_pos
and _rl_screenwidth */
- if (col_lendiff && (_rl_last_c_pos < _rl_screenwidth))
+ if (col_lendiff && ((MB_CUR_MAX == 1 || rl_byte_oriented) || (_rl_last_c_pos < _rl_screenwidth)))
#endif
{
if (_rl_term_autowrap && current_line < inv_botlin)
@@ -1892,6 +1903,10 @@ _rl_move_cursor_relative (new, data)
woff = WRAP_OFFSET (_rl_last_v_pos, wrap_offset);
cpos = _rl_last_c_pos;
+
+ if (cpos == 0 && cpos == new)
+ return;
+
#if defined (HANDLE_MULTIBYTE)
/* If we have multibyte characters, NEW is indexed by the buffer point in
a multibyte string, but _rl_last_c_pos is the display position. In
@@ -1905,9 +1920,9 @@ _rl_move_cursor_relative (new, data)
prompt string, since they're both buffer indices and DPOS is a
desired display position. */
if ((new > prompt_last_invisible) || /* XXX - don't use woff here */
- (prompt_physical_chars > _rl_screenwidth &&
+ (prompt_physical_chars >= _rl_screenwidth &&
_rl_last_v_pos == prompt_last_screen_line &&
- wrap_offset >= woff &&
+ wrap_offset >= woff && dpos >= woff &&
new > (prompt_last_invisible-(_rl_screenwidth*_rl_last_v_pos)-wrap_offset)))
/* XXX last comparison might need to be >= */
{
diff --git a/patchlevel b/patchlevel
index d8c9df7..e0ba09d 100644
--- a/patchlevel
+++ b/patchlevel
@@ -1,3 +1,3 @@
# Do not edit -- exists only for use by patch
-0
+5
diff --git a/readline.h b/readline.h
index ba0d5d6..fa02dec 100644
--- a/readline.h
+++ b/readline.h
@@ -814,8 +814,9 @@ extern int rl_inhibit_completion;
#define RL_STATE_VIMOTION 0x100000 /* reading vi motion arg */
#define RL_STATE_MULTIKEY 0x200000 /* reading multiple-key command */
#define RL_STATE_VICMDONCE 0x400000 /* entered vi command mode at least once */
+#define RL_STATE_REDISPLAYING 0x800000 /* updating terminal display */
-#define RL_STATE_DONE 0x800000 /* done; accepted line */
+#define RL_STATE_DONE 0x1000000 /* done; accepted line */
#define RL_SETSTATE(x) (rl_readline_state |= (x))
#define RL_UNSETSTATE(x) (rl_readline_state &= ~(x))
diff --git a/terminal.c b/terminal.c
index 87fdf10..768ec9b 100644
--- a/terminal.c
+++ b/terminal.c
@@ -355,7 +355,7 @@ rl_resize_terminal ()
_rl_get_screen_size (fileno (rl_instream), 1);
if (CUSTOM_REDISPLAY_FUNC ())
rl_forced_update_display ();
- else
+ else if (RL_ISSTATE(RL_STATE_REDISPLAYING) == 0)
_rl_redisplay_after_sigwinch ();
}
}