summaryrefslogtreecommitdiff
path: root/main/editline
diff options
context:
space:
mode:
Diffstat (limited to 'main/editline')
-rw-r--r--main/editline/INSTALL4
-rw-r--r--main/editline/chared.c4
-rwxr-xr-xmain/editline/configure36
-rw-r--r--main/editline/configure.in15
-rwxr-xr-xmain/editline/install-sh16
-rw-r--r--main/editline/map.c2
-rw-r--r--main/editline/np/unvis.c34
-rw-r--r--main/editline/np/vis.c12
-rw-r--r--main/editline/read.h2
-rw-r--r--main/editline/readline.c4
-rw-r--r--main/editline/refresh.c6
-rw-r--r--main/editline/term.c4
12 files changed, 68 insertions, 71 deletions
diff --git a/main/editline/INSTALL b/main/editline/INSTALL
index 16fb6ffd1..05e00f71c 100644
--- a/main/editline/INSTALL
+++ b/main/editline/INSTALL
@@ -29,7 +29,7 @@ Optionally, pass any of the following (not a definitive list) arguments to
--prefix=<install-root-dir>
Set the base directory in which to install. For example:
-
+
./configure --prefix=/usr/local
will cause files to be installed into /usr/local/bin, /usr/local/man,
@@ -51,7 +51,7 @@ CFLAGS="?"
CPPFLAGS="?"
Pass these flags to the C preprocessor. Note that CFLAGS is not passed
- to 'cpp' when 'configure' is looking for include files, so you must use
+ to 'cpp' when 'configure' is looking for include files, so you must use
CPPFLAGS instead if you need to help 'configure' find header files.
LD_LIBRARY_PATH="?"
diff --git a/main/editline/chared.c b/main/editline/chared.c
index 8eaeb3b54..d0a03e2ad 100644
--- a/main/editline/chared.c
+++ b/main/editline/chared.c
@@ -515,7 +515,7 @@ ch_enlargebufs(el, addlen)
/* zero the newly added memory, leave old data in */
(void) memset(&newbuffer[sz], 0, newsz - sz);
-
+
oldbuf = el->el_line.buffer;
el->el_line.buffer = newbuffer;
@@ -554,7 +554,7 @@ ch_enlargebufs(el, addlen)
el->el_chared.c_undo.ptr = el->el_line.buffer +
(el->el_chared.c_undo.ptr - oldbuf);
el->el_chared.c_undo.buf = newbuffer;
-
+
if (!hist_enlargebuf(el, sz, newsz))
return 0;
diff --git a/main/editline/configure b/main/editline/configure
index d5d0a4dea..ea180bce2 100755
--- a/main/editline/configure
+++ b/main/editline/configure
@@ -1,7 +1,7 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13
+# Generated automatically using autoconf version 2.13
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
#
# This configure script is free software; the Free Software Foundation
@@ -932,15 +932,15 @@ case "${host}" in
if echo ${host} | grep -q cygwin ; then \
echo "cygwin detected"; \
S_CFLAGS=""; \
- echo "/* cygdef.h. Generated automatically by configure. */
+ echo "/* cygdef.h. Generated automatically by configure. */
#ifndef _CYGDEF_H_
#define _CYGDEF_H_ 1
#include <sys/ioctl.h>
#define __linux__ 1
-
+
typedef void (*sig_t)(int);
-
+
#endif /* _CYGDEF_H_ */" > cygdef.h; \
echo "
@@ -1092,13 +1092,13 @@ else
/*)
ac_cv_path_AR="$AR" # Let the user override the test with a path.
;;
- ?:/*)
+ ?:/*)
ac_cv_path_AR="$AR" # Let the user override the test with a dos path.
;;
*)
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
+ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if test -f $ac_dir/$ac_word; then
ac_cv_path_AR="$ac_dir/$ac_word"
@@ -1348,7 +1348,7 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
\
@@ -1386,7 +1386,7 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
\
@@ -1428,7 +1428,7 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
\
@@ -1466,7 +1466,7 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
\
@@ -1515,7 +1515,7 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
fi
@@ -1571,7 +1571,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
fi
@@ -1626,7 +1626,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
CCSRCS="$CCSRCS np/fgetln.c"
@@ -1682,7 +1682,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
CCSRCS="$CCSRCS np/vis.c"
@@ -1738,7 +1738,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
CCSRCS="$CCSRCS np/unvis.c"
@@ -1794,7 +1794,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
CCSRCS="$CCSRCS np/strlcpy.c"
@@ -1850,7 +1850,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
-
+
else
echo "$ac_t""no" 1>&6
CCSRCS="$CCSRCS np/strlcat.c"
@@ -2460,5 +2460,3 @@ EOF
chmod +x $CONFIG_STATUS
rm -fr confdefs* $ac_clean_files
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
-
diff --git a/main/editline/configure.in b/main/editline/configure.in
index d8bc706b1..bd99b5a86 100644
--- a/main/editline/configure.in
+++ b/main/editline/configure.in
@@ -1,6 +1,6 @@
-dnl
+dnl
dnl Process this file with autoconf to produce a configure script.
-dnl
+dnl
AC_INIT(Makefile.in)
dnl If CFLAGS isn't defined and using gcc, set CFLAGS to something reasonable.
@@ -36,15 +36,15 @@ case "${host}" in
if echo ${host} | grep -q cygwin ; then \
echo "cygwin detected"; \
S_CFLAGS=""; \
- echo "/* cygdef.h. Generated automatically by configure. */
+ echo "/* cygdef.h. Generated automatically by configure. */
#ifndef _CYGDEF_H_
#define _CYGDEF_H_ 1
#include <sys/ioctl.h>
#define __linux__ 1
-
+
typedef void (*sig_t)(int);
-
+
#endif /* _CYGDEF_H_ */" > cygdef.h; \
echo "
@@ -155,10 +155,10 @@ else
fi
-dnl
+dnl
dnl File lists. This is done here instead of in the Makefile in order to avoid
dnl the need for conditionals.
-dnl
+dnl
dnl .c files.
ACSRCS="common.c emacs.c vi.c"
@@ -275,4 +275,3 @@ AC_SUBST(TCSRCS)
AC_CONFIG_HEADER(config.h)
AC_OUTPUT([Makefile makelist])
-
diff --git a/main/editline/install-sh b/main/editline/install-sh
index ebc66913e..058b26c82 100755
--- a/main/editline/install-sh
+++ b/main/editline/install-sh
@@ -115,7 +115,7 @@ fi
if [ x"$dir_arg" != x ]; then
dst=$src
src=""
-
+
if [ -d $dst ]; then
instcmd=:
else
@@ -124,7 +124,7 @@ if [ x"$dir_arg" != x ]; then
else
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
-# might cause directories to be created, which would be especially bad
+# might cause directories to be created, which would be especially bad
# if $src (and thus $dsttmp) contains '*'.
if [ -f $src -o -d $src ]
@@ -134,7 +134,7 @@ else
echo "install: $src does not exist"
exit 1
fi
-
+
if [ x"$dst" = x ]
then
echo "install: no destination specified"
@@ -162,7 +162,7 @@ dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
# Skip lots of stat calls in the usual case.
if [ ! -d "$dstdir" ]; then
-defaultIFS='
+defaultIFS='
'
IFS="${IFS-${defaultIFS}}"
@@ -201,17 +201,17 @@ else
# If we're going to rename the final executable, determine the name now.
- if [ x"$transformarg" = x ]
+ if [ x"$transformarg" = x ]
then
dstfile=`basename $dst`
else
- dstfile=`basename $dst $transformbasename |
+ dstfile=`basename $dst $transformbasename |
sed $transformarg`$transformbasename
fi
# don't allow the sed command to completely eliminate the filename
- if [ x"$dstfile" = x ]
+ if [ x"$dstfile" = x ]
then
dstfile=`basename $dst`
else
@@ -242,7 +242,7 @@ else
# Now rename the file to the real destination.
$doit $rmcmd -f $dstdir/$dstfile &&
- $doit $mvcmd $dsttmp $dstdir/$dstfile
+ $doit $mvcmd $dsttmp $dstdir/$dstfile
fi &&
diff --git a/main/editline/map.c b/main/editline/map.c
index 4187cb597..448c3c0ca 100644
--- a/main/editline/map.c
+++ b/main/editline/map.c
@@ -369,7 +369,7 @@ private const el_action_t el_map_vi_insert[] = {
* NOTE: These mappings do NOT Correspond well
* to the KSH VI editing assignments.
* On the other and they are convenient and
- * many people have have gotten used to them.
+ * many people have gotten used to them.
*/
/* 0 */ ED_UNASSIGNED, /* ^@ */
/* 1 */ ED_MOVE_TO_BEG, /* ^A */
diff --git a/main/editline/np/unvis.c b/main/editline/np/unvis.c
index 844a5581b..0a26e3d63 100644
--- a/main/editline/np/unvis.c
+++ b/main/editline/np/unvis.c
@@ -105,7 +105,7 @@ __unvis13(cp, c, astate, flag)
|| *astate == S_HEX2) {
*astate = S_GROUND;
return (UNVIS_VALID);
- }
+ }
return (*astate == S_GROUND ? UNVIS_NOCHAR : UNVIS_SYNBAD);
}
@@ -116,7 +116,7 @@ __unvis13(cp, c, astate, flag)
if (c == '\\') {
*astate = S_START;
return (0);
- }
+ }
if ((flag & VIS_HTTPSTYLE) && c == '%') {
*astate = S_HEX1;
return (0);
@@ -193,7 +193,7 @@ __unvis13(cp, c, astate, flag)
}
*astate = S_GROUND;
return (UNVIS_SYNBAD);
-
+
case S_META:
if (c == '-')
*astate = S_META1;
@@ -204,12 +204,12 @@ __unvis13(cp, c, astate, flag)
return (UNVIS_SYNBAD);
}
return (0);
-
+
case S_META1:
*astate = S_GROUND;
*cp |= c;
return (UNVIS_VALID);
-
+
case S_CTRL:
if (c == '?')
*cp |= 0177;
@@ -220,15 +220,15 @@ __unvis13(cp, c, astate, flag)
case S_OCTAL2: /* second possible octal digit */
if (isoctal(c)) {
- /*
- * yes - and maybe a third
+ /*
+ * yes - and maybe a third
*/
*cp = (*cp << 3) + (c - '0');
- *astate = S_OCTAL3;
+ *astate = S_OCTAL3;
return (0);
- }
- /*
- * no - done with current sequence, push back passed char
+ }
+ /*
+ * no - done with current sequence, push back passed char
*/
*astate = S_GROUND;
return (UNVIS_VALIDPUSH);
@@ -249,8 +249,8 @@ __unvis13(cp, c, astate, flag)
*astate = S_HEX2;
return (0);
}
- /*
- * no - done with current sequence, push back passed char
+ /*
+ * no - done with current sequence, push back passed char
*/
*astate = S_GROUND;
return (UNVIS_VALIDPUSH);
@@ -261,9 +261,9 @@ __unvis13(cp, c, astate, flag)
return (UNVIS_VALID);
}
return (UNVIS_VALIDPUSH);
- default:
- /*
- * decoder in unknown state - (probably uninitialized)
+ default:
+ /*
+ * decoder in unknown state - (probably uninitialized)
*/
*astate = S_GROUND;
return (UNVIS_SYNBAD);
@@ -271,7 +271,7 @@ __unvis13(cp, c, astate, flag)
}
/*
- * strunvis - decode src into dst
+ * strunvis - decode src into dst
*
* Number of chars decoded into dst is returned, -1 on error.
* Dst is null terminated.
diff --git a/main/editline/np/vis.c b/main/editline/np/vis.c
index bd8192440..264dce629 100644
--- a/main/editline/np/vis.c
+++ b/main/editline/np/vis.c
@@ -111,7 +111,7 @@ do \
SVIS(dst, c, flag, nextc, extra); \
} \
while (/*CONSTCOND*/0)
-
+
/*
* This is SVIS, the central macro of vis.
* dst: Pointer to the destination buffer
@@ -219,10 +219,10 @@ svis(dst, c, flag, nextc, extra)
* be encoded, too. These functions are useful e. g. to
* encode strings in such a way so that they are not interpreted
* by a shell.
- *
+ *
* Dst must be 4 times the size of src to account for possible
* expansion. The length of dst, not including the trailing NULL,
- * is returned.
+ * is returned.
*
* Strsvisx encodes exactly len bytes from src into dst.
* This is useful for encoding a block of data.
@@ -294,7 +294,7 @@ char *
vis(dst, c, flag, nextc)
char *dst;
int c, flag, nextc;
-
+
{
char *extra;
@@ -312,10 +312,10 @@ vis(dst, c, flag, nextc)
/*
* strvis, strvisx - visually encode characters from src into dst
- *
+ *
* Dst must be 4 times the size of src to account for possible
* expansion. The length of dst, not including the trailing NULL,
- * is returned.
+ * is returned.
*
* Strvisx encodes exactly len bytes from src into dst.
* This is useful for encoding a block of data.
diff --git a/main/editline/read.h b/main/editline/read.h
index b01e77db2..716a51693 100644
--- a/main/editline/read.h
+++ b/main/editline/read.h
@@ -47,7 +47,7 @@ typedef int (*el_rfunc_t)(EditLine *, char *);
typedef struct el_read_t {
el_rfunc_t read_char; /* Function to read a character */
} el_read_t;
-
+
protected int read_init(EditLine *);
protected int el_read_setfn(EditLine *, el_rfunc_t);
protected el_rfunc_t el_read_getfn(EditLine *);
diff --git a/main/editline/readline.c b/main/editline/readline.c
index 48a843df2..7389c1886 100644
--- a/main/editline/readline.c
+++ b/main/editline/readline.c
@@ -250,7 +250,7 @@ rl_initialize(void)
break;
}
}
-
+
/* read settings from configuration file */
el_source(e, NULL);
@@ -1531,7 +1531,7 @@ rl_complete_internal(int what_to_do)
maxlen = match_len;
}
matches_num = i - 1;
-
+
/* newline to get on next line from command line */
fprintf(e->el_outfile, "\n");
diff --git a/main/editline/refresh.c b/main/editline/refresh.c
index fcebe1253..fe3ac440f 100644
--- a/main/editline/refresh.c
+++ b/main/editline/refresh.c
@@ -166,7 +166,7 @@ re_putc(EditLine *el, int c, int shift)
for(i=1; i < lins; i++)
el->el_vdisplay[i-1] = el->el_vdisplay[i];
- firstline[0] = '\0'; /* empty the string */
+ firstline[0] = '\0'; /* empty the string */
el->el_vdisplay[i-1] = firstline;
} else
el->el_refresh.r_cursor.v++;
@@ -1002,7 +1002,7 @@ re_fastputc(EditLine *el, int c)
if (el->el_cursor.v + 1 >= el->el_term.t_size.v) {
int i, lins = el->el_term.t_size.v;
char *firstline = el->el_display[0];
-
+
for(i=1; i < lins; i++)
el->el_display[i-1] = el->el_display[i];
@@ -1064,7 +1064,7 @@ re_fastaddc(EditLine *el)
/* re_clear_display():
- * clear the screen buffers so that new new prompt starts fresh.
+ * clear the screen buffers so that new prompt starts fresh.
*/
protected void
re_clear_display(EditLine *el)
diff --git a/main/editline/term.c b/main/editline/term.c
index 00b68ed33..6814cc4ca 100644
--- a/main/editline/term.c
+++ b/main/editline/term.c
@@ -428,7 +428,7 @@ term_alloc(EditLine *el, const struct termcapstr *t, const char *cap)
*/
tlen = 0;
for (tmp = tlist; tmp < &tlist[T_str]; tmp++)
- if (*tmp != NULL && *tmp != '\0' && *tmp != *str) {
+ if (*tmp != NULL && **tmp != '\0' && *tmp != *str) {
char *ptr;
for (ptr = *tmp; *ptr != '\0'; termbuf[tlen++] = *ptr++)
@@ -640,7 +640,7 @@ mc_again:
(el->el_cursor.h & 0370);
i < (where & 0370);
i += 8)
- term__putc('\t');
+ term__putc('\t');
/* then tab over */
el->el_cursor.h = where & 0370;
}