Commit 1b174d6c authored by Dmitry Chagin's avatar Dmitry Chagin
Browse files

Import 6.22.03-ceccc7f

parent 03282ad8
This diff is collapsed.
14. Don't crash with 'bindkey "^0" clear-screen' (Karl Jeacle)
13. Fix $x:q:h and $x:q:t return the whole string for strings not containing /
12. V6.22.03 - 20201118
11. Fix $x:q:h and $x:q:t to not crash (alzwded) with strings containing /
10. Block SIGHUP while writing history/directory stack (Brett Frankenberger)
9. Fixed reversed test that broke history merging (Brett Frankenberger)
8. Prevent recursive entry for writing history (Brett Frankenberger)
7. alxwded@github, keep track of the :g and :a modifiers per modifier they
affect.
6. alzwded@github, fix infinite loop with :gas variable modifier
5. PR/88: Add a Q: modifier that preserves empty arguments leaving :q
alone.
4. V6.22.02 - 20191204
3. Fix version in configure.ac
2. V6.22.01 - 20191201
1. undo PR/88: Preserve empty arguments in :q, since it breaks
$ set x=""
$ alias test "echo "\""$x:q"\"" is working."
$ alias test
echo "
6. V6.22.00 - 20191128
5. PR/113: Sobomax: avoid infinite loops for -c commands when stdout is
not a tty.
4. Avoid infinite loops during history loads when merging, print a better
......@@ -6,6 +28,7 @@
2. PR/94: Small apple issues (SAVESIGVEC, HOSTTYPE)
1. PR/81: Fix range matching issue where we were comparing with the
range character instead of the start of range. [l-z]* would match foo
12. V6.21.00 - 20190508
11. Abort history loading on words and lines too long
https://bugzilla.redhat.com/show_bug.cgi?id=1598502
......
......@@ -492,14 +492,15 @@ SHSRCS= sh.c sh.dir.c sh.dol.c sh.err.c sh.exec.c \
sh.char.c sh.exp.c sh.file.c sh.func.c \
sh.glob.c sh.hist.c sh.init.c sh.lex.c \
sh.misc.c sh.parse.c sh.print.c sh.proc.c \
sh.sem.c sh.set.c sh.time.c glob.c \
sh.sem.c sh.set.c sh.time.c dotlock.c dotlock.h glob.c \
sh.char.h sh.dir.h sh.proc.h sh.h \
sh.decls.h glob.h ${SYSSRCS}
SHOBJS= sh.${SUF} sh.dir.${SUF} sh.dol.${SUF} sh.err.${SUF} sh.exec.${SUF} \
sh.char.${SUF} sh.exp.${SUF} sh.file.${SUF} sh.func.${SUF} \
sh.glob.${SUF} sh.hist.${SUF} sh.init.${SUF} sh.lex.${SUF} \
sh.misc.${SUF} sh.parse.${SUF} sh.print.${SUF} sh.proc.${SUF} \
sh.sem.${SUF} sh.set.${SUF} sh.time.${SUF} glob.${SUF} ${SYSOBJS}
sh.sem.${SUF} sh.set.${SUF} sh.time.${SUF} dotlock.${SUF} glob.${SUF} \
${SYSOBJS}
TWSRCS= tw.decls.h tw.h tw.help.c tw.init.c tw.parse.c tw.spell.c \
tw.comp.c tw.color.c
......@@ -512,9 +513,10 @@ EDOBJS= ed.chared.${SUF} ed.refresh.${SUF} ed.screen.${SUF} ed.init.${SUF} \
ed.inputl.${SUF} ed.defns.${SUF} ed.xmap.${SUF} ed.term.${SUF}
TCSRCS= tc.alloc.c tc.bind.c tc.const.c tc.decls.h tc.disc.c \
tc.func.c tc.os.c tc.os.h tc.printf.c tc.prompt.c \
tc.sched.c tc.sig.c tc.sig.h tc.str.c sh.types.h tc.vers.c tc.wait.h \
tc.who.c tc.h
tc.func.c tc.nls.c tc.nls.h tc.os.c tc.os.h tc.printf.c tc.prompt.c \
tc.disc.${SUF} tc.func.${SUF} tc.nls.${SUF} tc.os.${SUF} \
tc.printf.${SUF} tc.sched.c tc.sig.c tc.sig.h tc.str.c sh.types.h \
tc.vers.c tc.wait.h tc.who.c tc.h
TCOBJS= tc.alloc.${SUF} tc.bind.${SUF} tc.const.${SUF} tc.defs.${SUF} \
tc.disc.${SUF} tc.func.${SUF} tc.os.${SUF} tc.printf.${SUF} \
tc.prompt.${SUF} tc.sched.${SUF} tc.sig.${SUF} tc.str.${SUF} \
......@@ -524,7 +526,7 @@ MISCF = Makefile.std BUILDING Fixes MAKEDIFFS MAKESHAR NewThings README.md \
FAQ WishList config_f.h eight-bit.me glob.3 patchlevel.h pathnames.h \
tcsh.man Ported src.desc Imakefile imake.config complete.tcsh \
Makefile.vms termcap.vms snames.h host.defs gethost.c tcsh.man2html \
Makefile.in configure.ac Makefile.win32 aclocal.m4
Makefile.in configure.ac Makefile.win32 aclocal.m4 dot.login dot.tcshrc
CONFSRCS=config/[a-z]*
......
#
# Makefile.ADMIN
#
# Maintenance tasks
#
# You can refetch files from the website, then run "git diff" to
# sanity check any changes before committing.
#
LYNX= lynx -dump -nolist
TRIM= expand | sed -e 's/^ *$$//' | cat -s
WEB= https://www.tcsh.org
PAGES= FAQ
all: ${PAGES}
.for i in ${PAGES}
$i: force
${LYNX} ${WEB}/${i:tl}/ | ${TRIM} > ${.TARGET}
.endfor
.DUMMY: force
force:
......@@ -6,6 +6,7 @@
# things; Paul Placeway, CIS Dept., Ohio State University
#
SHELL=/bin/sh
ENVCMD=/usr/bin/env
VERSION=@PACKAGE_VERSION@
BUILD=tcsh$(EXEEXT)
VPATH=@srcdir@
......@@ -410,7 +411,7 @@ AVSRCS= BUILDING Fixes MAKEDIFFS MAKESHAR NewThings README.md FAQ \
pathnames.h tcsh.man Ported src.desc Imakefile imake.config \
complete.tcsh vmsreadme.txt termcap.vms snames.h host.defs \
gethost.c tcsh.man2html configure.ac configure config.h.in \
tests/testsuite.at aclocal.m4
tests/testsuite.at aclocal.m4 dot.login dot.tcshrc
TESTFILES= tests/aliases.at tests/arguments.at tests/commands.at \
tests/expr.at tests/lexical.at tests/mb-eucjp.at \
tests/mb-utf8.at tests/noexec.at tests/parenthesis.at tests/syntax.at \
......@@ -634,6 +635,8 @@ veryclean: clean
${RM} -f Makefile config.h config_p.h
${RM} -f config.status config.cache config.log tcsh.ps
${RM} -f missing
${RM} -f testsuite.log
${RM} -rf testsuite.dir
${RM} -rf autom4te.cache
${RM} -f *~ #*
......@@ -735,8 +738,10 @@ $(srcdir)/stamp-h.in: $(srcdir)/configure.ac
cd $(srcdir) && autoheader
@echo timestamp > $(srcdir)/stamp-h.in
check: atconfig $(srcdir)/tests/testsuite
$(SHELL) $(srcdir)/tests/testsuite
check test: atconfig $(srcdir)/tests/testsuite
$(ENVCMD) - \
USER="$(USER)" \
$(SHELL) $(srcdir)/tests/testsuite
#
# Dependencies
......
......@@ -320,7 +320,7 @@ AVSRCS= BUILDING Fixes MAKEDIFFS MAKESHAR NewThings README.md FAQ \
pathnames.h tcsh.man Ported src.desc Imakefile imake.config \
complete.tcsh vmsreadme.txt termcap.vms snames.h host.defs \
gethost.c tcsh.man2html configure.ac configure config.h.in \
aclocal.m4
aclocal.m4 dot.login dot.tcshrc
VHSRCS=${PVSRCS} ${AVSRCS}
......
......@@ -297,7 +297,7 @@ AVSRCS= BUILDING Fixes MAKEDIFFS MAKESHAR NewThings README.md FAQ \
WishList config_f.h eight-bit.me glob.3 patchlevel.h \
pathnames.h tcsh.man Ported src.desc Imakefile imake.config \
complete.tcsh vmsreadme.txt termcap.vms snames.h host.defs \
gethost.c tcsh.man2html configure.ac aclocal.m4
gethost.c tcsh.man2html configure.ac aclocal.m4 dot.login dot.tcshrc
VHSRCS=${PVSRCS} ${AVSRCS}
......
......@@ -5,7 +5,7 @@
The Tcsh source code is available on GitHub as a read-only repo
mirror at:
> http://github.com/tcsh-org/tcsh
> https://github.com/tcsh-org/tcsh
Instructions for compiling Tcsh can be found in [BUILDING].
......@@ -20,7 +20,10 @@ the tcsh mailing list:
> https://mailman.astron.com/mailman/listinfo/tcsh
[![Build Status][status]][travis]
[![Coverity Scan][badge]][coverity]
[BUILDING]: BUILDING
[status]: https://travis-ci.org/tcsh-org/tcsh.svg?branch=master
[travis]: https://travis-ci.org/tcsh-org/tcsh
[badge]: https://scan.coverity.com/projects/20307/badge.svg
[coverity]: https://scan.coverity.com/projects/tcsh-org-tcsh
[status]: https://travis-ci.com/tcsh-org/tcsh.svg?branch=master
[travis]: https://travis-ci.com/tcsh-org/tcsh
This diff is collapsed.
......@@ -83,9 +83,16 @@
*
* The more recent defaults for gcc (e.g. on Red Hat 7.0)
* also define _POSIX_C_SOURCE, which throws our code off.
*
* _BSD_SOURCE and _SVID_SOURCE have become deprecated
* aliases for _DEFAULT_SOURCE. _DEFAULT_SOURCE overrides
* __STRICT_ANSI__ also. [gcc 8.3.0 on Debian 10]
*/
#define __STRICT_ANSI__
#ifndef _DEFAULT_SOURCE
# define _DEFAULT_SOURCE
#endif
#ifndef _BSD_SOURCE
# define _BSD_SOURCE
#endif
......
This diff is collapsed.
......@@ -8,7 +8,7 @@ dnl
dnl Written by Kaveh Ghazi (ghazi@caip.rutgers.edu) 5/11/96.
AC_PREREQ([2.59])dnl Minimum Autoconf version required.
AC_INIT([tcsh], [6.21.00], [https://bugs.astron.com/])
AC_INIT([tcsh], [6.22.03], [https://bugs.astron.com/])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR([tc.vers.c])
AC_CONFIG_HEADERS([config.h])
......@@ -17,6 +17,8 @@ AC_CONFIG_TESTDIR([.], [.])
AC_PROG_INSTALL
AC_CANONICAL_HOST
AM_ICONV
AC_MSG_CHECKING([cached host tuple])
if { test x"${ac_cv_host_system_type+set}" = x"set" &&
test x"$ac_cv_host_system_type" != x"$host"; }; then
......@@ -321,7 +323,6 @@ AC_SEARCH_LIBS([tgetent], [termlib tinfo termcap curses ncurses], [], [
AC_SEARCH_LIBS(gethostbyname, nsl)
AC_SEARCH_LIBS(connect, socket)
AC_SEARCH_LIBS(catgets, catgets)
AM_ICONV
dnl Checks for header files
AC_CHECK_HEADERS([auth.h crypt.h features.h inttypes.h paths.h] dnl
......
#
# ~/.login - Setup user login shell environment
#
# See also tcsh(1), environ(7).
#
setenv EDITOR vi
setenv PAGER less
# umask 077
# set path=( ~/.local/bin $path:q )
#
# ~/.tcshrc - Setup user shell environment
#
# See also tcsh(1), environ(7).
#
unalias *
alias h 'history \!* 20'
alias j 'jobs -l'
alias ll 'ls -lAF'
alias md mkdir
alias rd rmdir
#
# The following commands are only for interactive shells.
#
if ( $?prompt ) then
set \
autocorrect \
autoexpand \
autolist=ambiguous \
correct=cmd \
ellipsis \
filec \
history=1000 \
killdup=erase \
listjobs=long \
listlinks \
listmax=100 \
nobeep \
prompt='%N@%m:%B%c02%b%# ' \
rmstar \
savehist=(1000 merge) \
unset promptchars
if ( $?tcsh ) then
bindkey -e
bindkey " " magic-space
bindkey ^W backward-delete-word
bindkey ^Z run-fg-editor
bindkey ^[^W kill-region
#
# Setup $hosts from ~/.hosts, ~/.rhosts, ~/.ssh/known_hosts
#
if ( ! $?hosts ) then
set hosts=()
foreach f ( ~/.{,r,ssh/known_}hosts )
if ( -r "$f" ) then
set hosts=( \
$hosts \
`sed \
-e 's/#.*//' \
-e '/^|/d' \
-e '/^[+-]@/d' \
-e 's/^[+-]//' \
-e 's/[[:space:]].*$//' \
-e 's/,/\n/g' \
"$f" \
| sed \
-e 's/:[[:digit:]]*$//' \
-e 's/^\[\([^]]*\)\]$/\1/' \
-e '/^[.:[:xdigit:][:space:]]*$/d' \
` \
)
endif
end
unset f
endif
uncomplete *
#
# Copy from complete.tcsh
#
if ( -r ~/.complete ) source ~/.complete
uncomplete rcp rsh
endif
#
# Set status to ^G in order to keep using ^T for transpose-char.
#
switch ( "$OSTYPE" )
case bsd44:
case darwin:
case FreeBSD:
case NetBSD:
stty status ^G
if ( $?tcsh ) bindkey ^G stuff-char
breaksw
endsw
#
# We don't want to create a root-owned files in our home.
#
if ( $uid == 0 ) then
unset savehist
setenv LESSHISTFILE -
setenv VIMINIT ':set viminfo='
endif
endif
......@@ -257,7 +257,7 @@ c_preword(Char *p, Char *low, int n, Char *delim)
Char *new;
while (prev < p) { /* Skip initial non-word chars */
if (!Strchr(delim, *prev) || *(prev-1) == (Char)'\\')
if (!Strchr(delim, *prev) || (prev > low && prev[-1] == (Char)'\\'))
break;
prev++;
}
......@@ -269,7 +269,7 @@ c_preword(Char *p, Char *low, int n, Char *delim)
new = c_endword(prev-1, p, 1, delim); /* Skip to next non-word char */
new++; /* Step away from end of word */
while (new <= p) { /* Skip trailing non-word chars */
if (!Strchr(delim, *new) || *(new-1) == (Char)'\\')
if (!Strchr(delim, *new) || new > prev && new[-1] == (Char)'\\')
break;
new++;
}
......@@ -795,19 +795,19 @@ c_endword(Char *p, Char *high, int n, Char *delim)
while (n--) {
while (p < high) { /* Skip non-word chars */
if (!Strchr(delim, *p) || *(p-1) == (Char)'\\')
if (!Strchr(delim, *p) || p[-1] == (Char)'\\')
break;
p++;
}
while (p < high) { /* Skip string */
if ((*p == (Char)'\'' || *p == (Char)'"')) { /* Quotation marks? */
if (inquote || *(p-1) != (Char)'\\') { /* Should it be honored? */
if (inquote || p[-1] != (Char)'\\') { /* Should it be honored? */
if (inquote == 0) inquote = *p;
else if (inquote == *p) inquote = 0;
}
}
/* Break if unquoted non-word char */
if (!inquote && Strchr(delim, *p) && *(p-1) != (Char)'\\')
if (!inquote && Strchr(delim, *p) && p[-1] != (Char)'\\')
break;
p++;
}
......@@ -1472,8 +1472,8 @@ e_insert(Char c)
else {
if (inputmode != MODE_INSERT) {
int i;
for(i = 0; i < Argument; i++)
UndoBuf[UndoSize++] = *(Cursor + i);
for (i = 0; i < Argument; i++)
UndoBuf[UndoSize++] = Cursor[i];
UndoBuf[UndoSize] = '\0';
c_delafter(Argument); /* Do NOT use the saving ONE */
......@@ -2923,7 +2923,7 @@ v_csearch_fwd(Char ch, int count, int tflag)
cp = Cursor;
while (count--) {
if(*cp == ch)
if (*cp == ch)
cp++;
while (cp < LastChar && *cp != ch)
cp++;
......@@ -3771,7 +3771,7 @@ v_undo(Char c)
size = (int)(Cursor-LastChar); /* NOT NSL independant */
if (size < UndoSize)
size = UndoSize;
for(loop = 0; loop < size; loop++) {
for (loop = 0; loop < size; loop++) {
temp = *kp;
*kp++ = *cp;
*cp++ = temp;
......
......@@ -862,7 +862,7 @@ SpellLine(int cmdonly)
/*
* This hack avoids correcting drive letter changes
*/
if((Cursor - InputBuf) != 2 || (char)InputBuf[1] != ':')
if ((Cursor - InputBuf) != 2 || (char)InputBuf[1] != ':')
#endif /* WINNT_NATIVE */
{
#ifdef HASH_SPELL_CHECK
......
......@@ -1217,7 +1217,7 @@ so_write(Char *cp, int n)
Char xc;
if ((xc = Display[CursorV][CursorH]) != '\0') {
so_write(&xc, 1);
while(Display[CursorV][CursorH] == CHAR_DBWIDTH)
while (Display[CursorV][CursorH] == CHAR_DBWIDTH)
CursorH++;
}
else {
......
......@@ -698,7 +698,7 @@ parseescape(const Char **ptr)
#endif
}
else
c = *p;
c = *p & CHAR;
*ptr = p;
return (c);
}
......
......@@ -851,7 +851,7 @@ machtype: defined(sparc) : "sparc"
enddef :
newdef : defined(APPLE) && defined(MACH)
newdef : defined(APPLE)
comment : OS X
vendor : : "apple"
hosttype: defined(i386) : "intel-mac"
......
......@@ -6,8 +6,8 @@
#define ORIGIN "Astron"
#define REV 6
#define VERS 21
#define PATCHLEVEL 00
#define DATE "2019-05-08"
#define VERS 22
#define PATCHLEVEL 03
#define DATE "2020-11-18"
#endif /* _h_patchlevel */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment