aboutsummaryrefslogtreecommitdiff
path: root/readline/histlib.h
diff options
context:
space:
mode:
authorElena Zannoni <ezannoni@kwikemart.cygnus.com>2000-07-09 17:20:00 +0000
committerElena Zannoni <ezannoni@kwikemart.cygnus.com>2000-07-09 17:20:00 +0000
commit1b17e766659d93d1e7bd6633bf78132e1abb3568 (patch)
tree6fa61b8b0140bca0772cdf39390405ca20fec949 /readline/histlib.h
parentd0352a18a504a4e7b761f6b3264cf11347d8d056 (diff)
downloadgdb-1b17e766659d93d1e7bd6633bf78132e1abb3568.zip
gdb-1b17e766659d93d1e7bd6633bf78132e1abb3568.tar.gz
gdb-1b17e766659d93d1e7bd6633bf78132e1abb3568.tar.bz2
readline:
2000-07-09 Elena Zannoni <ezannoni@kwikemart.cygnus.com> * Import of readline 4.1. Locally modified files: Makefile.in, configure.in, configure (regenerated), config.h.in (regenerated), readline.h, rltty.c, shell.c signals.c. Locally added files: acconfig.h, config/*, config.h.bot, cross-build/*, doc/inc-hit.texinfo. New files: USAGE, rlprivate.h, rlshell.h, xmalloc.h. examples: 2000-07-09 Elena Zannoni <ezannoni@kwikemart.cygnus.com> * Import of readline 4.1. New files: excallback.c, rlfe.c. doc: 2000-07-09 Elena Zannoni <ezannoni@kwikemart.cygnus.com> * Import of readline 4.1. Regenerated inc-hist.texinfo as copy of hsuser.texinfo, for inclusion in the gdb manual. New file: rluserman.texinfo
Diffstat (limited to 'readline/histlib.h')
-rw-r--r--readline/histlib.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/readline/histlib.h b/readline/histlib.h
index 422cf59..88a34d1 100644
--- a/readline/histlib.h
+++ b/readline/histlib.h
@@ -6,7 +6,7 @@
The Library is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
+ the Free Software Foundation; either version 2, or (at your option)
any later version.
The Library is distributed in the hope that it will be useful, but
@@ -17,7 +17,7 @@
The GNU General Public License is often shipped with GNU software, and
is generally kept in a file called COPYING or LICENSE. If you do not
have a copy of the license, write to the Free Software Foundation,
- 675 Mass Ave, Cambridge, MA 02139, USA. */
+ 59 Temple Place, Suite 330, Boston, MA 02111 USA. */
#if !defined (_HISTLIB_H_)
#define _HISTLIB_H_
@@ -31,8 +31,11 @@ typedef char *CPFunction ();
typedef char **CPPFunction ();
#endif /* _FUNCTION_DEF */
+#if !defined (STREQ)
#define STREQ(a, b) (((a)[0] == (b)[0]) && (strcmp ((a), (b)) == 0))
-#define STREQN(a, b, n) (((a)[0] == (b)[0]) && (strncmp ((a), (b), (n)) == 0))
+#define STREQN(a, b, n) (((n) == 0) ? (1) \
+ : ((a)[0] == (b)[0]) && (strncmp ((a), (b), (n)) == 0))
+#endif
#ifndef savestring
# ifndef strcpy
@@ -79,4 +82,7 @@ extern char *strchr ();
#define HISTORY_APPEND 0
#define HISTORY_OVERWRITE 1
+/* Some variable definitions shared across history source files. */
+extern int history_offset;
+
#endif /* !_HISTLIB_H_ */