tcsh: update to version 6.22.04.
Merge commit '174d8b60324d7e8754709f7155e13ca95220b48c' into main. MFC After: 2 weeks
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
|
15. V6.22.04 - 20210426
|
||||||
14. Don't crash with 'bindkey "^0" clear-screen' (Karl Jeacle)
|
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 /
|
13. Fix $x:q:h and $x:q:t return the whole string for strings not containing /
|
||||||
12. V6.22.03 - 20201118
|
12. V6.22.03 - 20201118
|
||||||
|
|||||||
@@ -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 = c_endword(prev-1, p, 1, delim); /* Skip to next non-word char */
|
||||||
new++; /* Step away from end of word */
|
new++; /* Step away from end of word */
|
||||||
while (new <= p) { /* Skip trailing non-word chars */
|
while (new <= p) { /* Skip trailing non-word chars */
|
||||||
if (!Strchr(delim, *new) || new > prev && new[-1] == (Char)'\\')
|
if (!Strchr(delim, *new) || (new > prev && new[-1] == (Char)'\\'))
|
||||||
break;
|
break;
|
||||||
new++;
|
new++;
|
||||||
}
|
}
|
||||||
|
|||||||
+6
-2
@@ -247,8 +247,12 @@ extern int tgetflag (const char *);
|
|||||||
extern int tgetnum (const char *);
|
extern int tgetnum (const char *);
|
||||||
extern char *tgoto (const char *, int, int);
|
extern char *tgoto (const char *, int, int);
|
||||||
extern void tputs (const char *, int, void (*)(int));
|
extern void tputs (const char *, int, void (*)(int));
|
||||||
# define PUTPURE ((void (*)(int)) putpure)
|
static __inline void PUTPURE(int c) {
|
||||||
# define PUTRAW ((void (*)(int)) putraw)
|
(void)putpure(c);
|
||||||
|
}
|
||||||
|
static __inline void PUTRAW(int c) {
|
||||||
|
(void)putraw(c);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* _h_ed */
|
#endif /* _h_ed */
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
#define ORIGIN "Astron"
|
#define ORIGIN "Astron"
|
||||||
#define REV 6
|
#define REV 6
|
||||||
#define VERS 22
|
#define VERS 22
|
||||||
#define PATCHLEVEL 03
|
#define PATCHLEVEL 04
|
||||||
#define DATE "2020-11-18"
|
#define DATE "2021-04-26"
|
||||||
|
|
||||||
#endif /* _h_patchlevel */
|
#endif /* _h_patchlevel */
|
||||||
|
|||||||
@@ -37,7 +37,7 @@
|
|||||||
*/
|
*/
|
||||||
extern Char *gethdir (const Char *);
|
extern Char *gethdir (const Char *);
|
||||||
extern void dosource (Char **, struct command *);
|
extern void dosource (Char **, struct command *);
|
||||||
extern void exitstat (void);
|
extern void exitstat (void) __attribute__((__noreturn__));
|
||||||
extern void goodbye (Char **, struct command *);
|
extern void goodbye (Char **, struct command *);
|
||||||
extern void importpath (Char *);
|
extern void importpath (Char *);
|
||||||
extern void initdesc (void);
|
extern void initdesc (void);
|
||||||
|
|||||||
@@ -781,7 +781,7 @@ fixDolMod(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
all_dolmcnts_are_0()
|
all_dolmcnts_are_0(void)
|
||||||
{
|
{
|
||||||
int i = 0;
|
int i = 0;
|
||||||
for (; i < ndolflags; ++i) {
|
for (; i < ndolflags; ++i) {
|
||||||
|
|||||||
+22
-10
@@ -205,25 +205,35 @@ addWordToHash(struct hashValue *h, const Char *word)
|
|||||||
{
|
{
|
||||||
uint32_t a = h->a, b = h->b, c = h->c;
|
uint32_t a = h->a, b = h->b, c = h->c;
|
||||||
#ifdef SHORT_STRINGS
|
#ifdef SHORT_STRINGS
|
||||||
|
#define GETK if ((k = (uChar)*word++) == 0) break
|
||||||
#ifdef WIDE_STRINGS
|
#ifdef WIDE_STRINGS
|
||||||
assert(sizeof(Char) >= 4);
|
assert(sizeof(Char) >= 4);
|
||||||
while (1) {
|
while (1) {
|
||||||
unsigned k;
|
unsigned k;
|
||||||
if ((k = (uChar)*word++) == 0) break; a += k;
|
GETK;
|
||||||
if ((k = (uChar)*word++) == 0) break; b += k;
|
a += k;
|
||||||
if ((k = (uChar)*word++) == 0) break; c += k;
|
GETK;
|
||||||
|
b += k;
|
||||||
|
GETK;
|
||||||
|
c += k;
|
||||||
mix(a, b, c);
|
mix(a, b, c);
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
assert(sizeof(Char) == 2);
|
assert(sizeof(Char) == 2);
|
||||||
while (1) {
|
while (1) {
|
||||||
unsigned k;
|
unsigned k;
|
||||||
if ((k = (uChar)*word++) == 0) break; a += k;
|
GETK;
|
||||||
if ((k = (uChar)*word++) == 0) break; a += k << 16;
|
a += k;
|
||||||
if ((k = (uChar)*word++) == 0) break; b += k;
|
GETK;
|
||||||
if ((k = (uChar)*word++) == 0) break; b += k << 16;
|
a += k << 16;
|
||||||
if ((k = (uChar)*word++) == 0) break; c += k;
|
GETK;
|
||||||
if ((k = (uChar)*word++) == 0) break; c += k << 16;
|
b += k;
|
||||||
|
GETK;
|
||||||
|
b += k << 16;
|
||||||
|
GETK;
|
||||||
|
c += k;
|
||||||
|
GETK;
|
||||||
|
c += k << 16;
|
||||||
mix(a, b, c);
|
mix(a, b, c);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -1216,18 +1226,20 @@ dotlock_cleanup(void* lockpath)
|
|||||||
|
|
||||||
/* Save history before exiting the shell. */
|
/* Save history before exiting the shell. */
|
||||||
void
|
void
|
||||||
rechist(Char *fname, int ref)
|
rechist(Char *xfname, int ref)
|
||||||
{
|
{
|
||||||
Char *snum, *rs;
|
Char *snum, *rs;
|
||||||
int fp, ftmp, oldidfds, ophup_disabled;
|
int fp, ftmp, oldidfds, ophup_disabled;
|
||||||
struct varent *shist;
|
struct varent *shist;
|
||||||
char path[MAXPATHLEN];
|
char path[MAXPATHLEN];
|
||||||
struct stat st;
|
struct stat st;
|
||||||
|
static Char *fname;
|
||||||
static Char *dumphist[] = {STRhistory, STRmhT, 0, 0};
|
static Char *dumphist[] = {STRhistory, STRmhT, 0, 0};
|
||||||
|
|
||||||
if (fname == NULL && !ref)
|
if (fname == NULL && !ref)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
fname = xfname;
|
||||||
ophup_disabled = phup_disabled;
|
ophup_disabled = phup_disabled;
|
||||||
phup_disabled = 1;
|
phup_disabled = 1;
|
||||||
|
|
||||||
|
|||||||
@@ -994,7 +994,7 @@ subword(Char *cp, Char type, int *adid, size_t *start_pos)
|
|||||||
case '\\':
|
case '\\':
|
||||||
if (np[1] == '&')
|
if (np[1] == '&')
|
||||||
np++;
|
np++;
|
||||||
/* fall into ... */
|
/* FALLTHROUGH */
|
||||||
|
|
||||||
default:
|
default:
|
||||||
Strbuf_append1(&wbuf, *np);
|
Strbuf_append1(&wbuf, *np);
|
||||||
@@ -1205,7 +1205,7 @@ gethent(Char sc)
|
|||||||
case '-':
|
case '-':
|
||||||
back = 1;
|
back = 1;
|
||||||
c = getC(0);
|
c = getC(0);
|
||||||
/* FALLSTHROUGH */
|
/* FALLTHROUGH */
|
||||||
|
|
||||||
default:
|
default:
|
||||||
if (any("(=~", c)) {
|
if (any("(=~", c)) {
|
||||||
|
|||||||
@@ -620,6 +620,7 @@ syn3(const struct wordent *p1, const struct wordent *p2, int flags)
|
|||||||
savep:
|
savep:
|
||||||
if (!specp)
|
if (!specp)
|
||||||
continue;
|
continue;
|
||||||
|
/* FALLTHROUGH */
|
||||||
default:
|
default:
|
||||||
if (l != 0 && !specp)
|
if (l != 0 && !specp)
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -77,7 +77,7 @@
|
|||||||
.\" used here if you can. In particular, please don't use nroff commands
|
.\" used here if you can. In particular, please don't use nroff commands
|
||||||
.\" which aren't already used herein.
|
.\" which aren't already used herein.
|
||||||
.\"
|
.\"
|
||||||
.TH TCSH 1 "11 Nov 2020" "Astron 6.22.03"
|
.TH TCSH 1 "26 Apr 2021" "Astron 6.22.04"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
tcsh \- C shell with file name completion and command line editing
|
tcsh \- C shell with file name completion and command line editing
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
@@ -5355,7 +5355,7 @@ pipe(2), setrlimit(2), sigvec(2), stat(2), umask(2), vfork(2), wait(2),
|
|||||||
malloc(3), setlocale(3), tty(4), a.out(5), termcap(5), environ(7),
|
malloc(3), setlocale(3), tty(4), a.out(5), termcap(5), environ(7),
|
||||||
termio(7), Introduction to the C Shell
|
termio(7), Introduction to the C Shell
|
||||||
.SH VERSION
|
.SH VERSION
|
||||||
This manual documents tcsh 6.22.03 (Astron) 2020-11-18.
|
This manual documents tcsh 6.22.04 (Astron) 2021-04-26.
|
||||||
.SH AUTHORS
|
.SH AUTHORS
|
||||||
.PD 0
|
.PD 0
|
||||||
.TP 2
|
.TP 2
|
||||||
|
|||||||
@@ -252,11 +252,13 @@ static void
|
|||||||
makecolor(char **c, int fg, int bg, Str *v)
|
makecolor(char **c, int fg, int bg, Str *v)
|
||||||
{
|
{
|
||||||
int l;
|
int l;
|
||||||
if (fg & 0x80)
|
if (fg & 0x80) {
|
||||||
l = xsnprintf(*c, 12, "%.2d;%.2d;%.2d;%.2d", ANSI_BOLD_ON,
|
l = xsnprintf(*c, 12, "%.2d;%.2d;%.2d;%.2d", ANSI_BOLD_ON,
|
||||||
fg & ~TCSH_BOLD, (10 + bg) & ~TCSH_BOLD, ANSI_BOLD_OFF);
|
fg & ~TCSH_BOLD, (10 + bg) & ~TCSH_BOLD, ANSI_BOLD_OFF);
|
||||||
|
} else {
|
||||||
l = xsnprintf(*c, 6, "%.2d;%.2d",
|
l = xsnprintf(*c, 6, "%.2d;%.2d",
|
||||||
fg & ~TCSH_BOLD, (10 + bg) & ~TCSH_BOLD);
|
fg & ~TCSH_BOLD, (10 + bg) & ~TCSH_BOLD);
|
||||||
|
}
|
||||||
|
|
||||||
v->s = *c;
|
v->s = *c;
|
||||||
v->len = l;
|
v->len = l;
|
||||||
|
|||||||
Reference in New Issue
Block a user