OBS User unknown 2009-03-25 18:00:28 +00:00 committed by Git OBS Bridge
parent 19400db04b
commit 0634d42bec
9 changed files with 146 additions and 51 deletions

View File

@ -14,13 +14,13 @@
set noglob
#
set hosts
foreach _f ($HOME/.hosts /etc/csh.hosts $HOME/.rhosts /etc/hosts.equiv)
foreach _f ("$HOME/.hosts" /etc/csh.hosts "$HOME/.rhosts" /etc/hosts.equiv)
if ( -r $_f ) then
set hosts=($hosts `grep -E -shv '^#|\+' $_f |awk '{ print $1 }'`)
endif
end
if ( -r $HOME/.netrc ) then
set _f=`awk '/machine/ { print $2 }' < $HOME/.netrc` >& /dev/null
if ( -r "$HOME/.netrc" ) then
set _f=`awk '/machine/ { print $2 }' < "$HOME/.netrc"` >& /dev/null
set hosts=($hosts $_f)
endif
set hosts=(`echo $hosts localhost $HOSTNAME|tr ' ' '\n'|sort -u -t '.'`)
@ -37,7 +37,7 @@
complete ispell c/-/"(a A b B C d D e ee f L m M p s S T v vv w W)"/ \
n/-d/"(english deutsch)"/ \
n/-T/"(tex plaintex nroff latin1 ascii atari)"/ \
n@-p@'`ls -1 $HOME/.ispell_*`'@ \
n@-p@'`ls -1 "$HOME"/.ispell_*`'@ \
n/-W/"(1 2 3 4 5)"/ \
n/-L/x:'ispell -L <number>'/ \
n/-f/t/ n/*/f:^*.{dvi,ps,a,o,gz,z,Z}/
@ -191,7 +191,7 @@
# these should be merged with the MH completion hacks below - jgotts
complete {sprev,snext} \
c@+@F:$HOME/Mail/@
c@+@F:"$HOME/Mail/"@
# these and interrupt handling from Jaap Vermeulen <jaap@sequent.com>
complete {rexec,rxexec,rxterm,rmterm} \
@ -239,10 +239,10 @@
if ( $?SKIP_MH ) goto skip_mh
# Do not be fooled by asking MH tools
if ( ! -r $HOME/.mh_profile ) goto skip_mh
if ( ! -r "$HOME/.mh_profile" ) goto skip_mh
# Do not be fooled by broken MH profile
if ( ! `grep -cE '^Path:' $HOME/.mh_profile` ) goto skip_mh
if ( ! `grep -cE '^Path:' "$HOME/.mh_profile"` ) goto skip_mh
if ( ! $?FOLDERS ) then
which folders >& /dev/null
@ -557,7 +557,7 @@ skip_mh:
kill password ping processlist reload refresh \
shutdown status variables version)/'
set _muttalias=/dev/null
foreach _f ($HOME/.muttrc-alias $HOME/.muttalias)
foreach _f ("$HOME/.muttrc-alias" "$HOME/.muttalias")
if ( -r $_f ) then
set _muttalias=$_f
break
@ -667,14 +667,14 @@ skip_mh:
endif
complete unsetenv n/*/e/
if (-r $HOME/.mailrc) then
if (-r "$HOME/.mailrc") then
complete mail c/-/"(e i f n s u v)"/ c/*@/\$hosts/ \
c@+@F:$HOME/Mail@ C@[./\$~]@f@ n/-s/x:'<subject>'/ \
c@+@F:"$HOME/Mail"@ C@[./\$~]@f@ n/-s/x:'<subject>'/ \
n@-u@T:$_maildir@ n/-f/f/ \
n@*@'`sed -n s/alias//p $HOME/.mailrc | tr -s " " "\t" | cut -f 2`'@
n@*@'`sed -n s/alias//p "$HOME/.mailrc" | tr -s " " "\t" | cut -f 2`'@
else
complete mail c/-/"(e i f n s u v)"/ c/*@/\$hosts/ \
c@+@F:$HOME/Mail@ C@[./\$~]@f@ n/-s/x:'<subject>'/ \
c@+@F:"$HOME/Mail"@ C@[./\$~]@f@ n/-s/x:'<subject>'/ \
n@-u@T:$_maildir@ n/-f/f/ n/*/u/
endif

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:66129f5c288432741419c2bf6cf7567f7349b453acd25bbfc4bea0fd3d81a165
size 727440

94
tcsh-6.16.00-grabpgrp.dif Normal file
View File

@ -0,0 +1,94 @@
--- sh.c
+++ sh.c 25 Feb 2009 22:53:47 -0000
@@ -1103,17 +1103,7 @@
}
#endif /* NeXT */
#ifdef BSDJOBS /* if we have tty job control */
- retry:
- if ((tpgrp = tcgetpgrp(f)) != -1) {
- if (tpgrp != shpgrp) {
- struct sigaction old;
-
- sigaction(SIGTTIN, NULL, &old);
- signal(SIGTTIN, SIG_DFL);
- (void) kill(0, SIGTTIN);
- sigaction(SIGTTIN, &old, NULL);
- goto retry;
- }
+ if (grabpgrp(f, shpgrp) != -1) {
/*
* Thanks to Matt Day for the POSIX references, and to
* Paul Close for the SGI clarification.
@@ -2356,3 +2346,28 @@
rechist(NULL, adrof(STRsavehist) != NULL);
}
}
+
+/*
+ * Grab the tty repeatedly, and give up if we are not in the correct
+ * tty process group.
+ */
+int
+grabpgrp(int fd, pid_t desired)
+{
+ struct sigaction old;
+ pid_t pgrp;
+ size_t i;
+
+ for (i = 0; i < 100; i++) {
+ if ((pgrp = tcgetpgrp(fd)) == -1)
+ return -1;
+ if (pgrp == desired)
+ return 0;
+ (void)sigaction(SIGTTIN, NULL, &old);
+ (void)signal(SIGTTIN, SIG_DFL);
+ (void)kill(0, SIGTTIN);
+ (void)sigaction(SIGTTIN, &old, NULL);
+ }
+ errno = EPERM;
+ return -1;
+}
--- sh.decls.h
+++ sh.decls.h 25 Feb 2009 22:53:47 -0000
@@ -52,6 +52,7 @@
#else
extern void xexit (int);
#endif
+extern int grabpgrp (int, pid_t);
/*
* sh.dir.c
--- sh.func.c
+++ sh.func.c 25 Feb 2009 22:53:47 -0000
@@ -2272,10 +2272,9 @@
dosuspend(Char **v, struct command *c)
{
#ifdef BSDJOBS
- int ctpgrp;
struct sigaction old;
#endif /* BSDJOBS */
-
+
USE(c);
USE(v);
@@ -2295,17 +2294,8 @@
#ifdef BSDJOBS
if (tpgrp != -1) {
-retry:
- ctpgrp = tcgetpgrp(FSHTTY);
- if (ctpgrp == -1)
+ if (grabpgrp(FSHTTY, opgrp) == -1)
stderror(ERR_SYSTEM, "tcgetpgrp", strerror(errno));
- if (ctpgrp != opgrp) {
- sigaction(SIGTTIN, NULL, &old);
- signal(SIGTTIN, SIG_DFL);
- (void) kill(0, SIGTTIN);
- sigaction(SIGTTIN, &old, NULL);
- goto retry;
- }
(void) setpgid(0, shpgrp);
(void) tcsetpgrp(FSHTTY, shpgrp);
}

View File

@ -10,7 +10,7 @@
void
pintr(void)
--- sh.err.c
+++ sh.err.c 2007-10-15 11:53:17.760845847 +0200
+++ sh.err.c 2009-03-25 11:35:16.552001834 +0100
@@ -51,6 +51,7 @@ char *seterr = NULL; /* Holds last err
#define ERR_NAME 0x10000000
#define ERR_SILENT 0x20000000
@ -19,17 +19,17 @@
#define ERR_SYNTAX 0
#define ERR_NOTALLOWED 1
@@ -600,7 +601,8 @@ stderror(unsigned int id, ...)
* else to FSHOUT/FSHDIAG. See flush in sh.print.c.
*/
flush();/*FIXRESET*/
- haderr = 1; /* Now to diagnostic output */
+ if (!(flags & ERR_INTERRUPT))
+ haderr = 1; /* Now to diagnostic output */
if (!(flags & ERR_SILENT)) {
@@ -609,7 +610,8 @@ stderror(unsigned int id, ...)
* sh.print.c.
*/
flush();/*FIXRESET*/
- haderr = 1; /* Now to diagnostic output */
+ if (!(flags & ERR_INTERRUPT))
+ haderr = 1; /* Now to diagnostic output */
if (flags & ERR_NAME)
@@ -643,5 +645,6 @@ stderror(unsigned int id, ...)
xprintf("%s: ", bname);/*FIXRESET*/
if ((flags & ERR_OLD)) {
@@ -650,5 +652,6 @@ stderror(unsigned int id, ...)
if (tpgrp > 0)
(void) tcsetpgrp(FSHTTY, tpgrp);
#endif

View File

@ -34,14 +34,3 @@
f->name = NULL;
f->func = 0;
f->desc = NULL;
--- tw.parse.c
+++ tw.parse.c 2007-08-28 12:03:41.288831024 +0200
@@ -433,7 +433,7 @@ tenematch(Char *inputline, int num_read,
Char *p;
int found;
- found = !cmd_expand(qline.s + wordp, &p);
+ found = cmd_expand(qline.s + wordp, &p);
if (!found) {
xfree(p);

View File

@ -190,18 +190,18 @@
#endif /* _CRAYCOM && !_PATH_TCSHELL */
--- sh.c
+++ sh.c 2006-04-25 14:58:31.000000000 +0200
@@ -456,7 +456,8 @@ main(int argc, char **argv)
+++ sh.c 2009-03-25 11:45:13.676501240 +0100
@@ -454,7 +454,8 @@ main(int argc, char **argv)
if (loginsh || (uid == 0)) {
if (*cp) {
/* only for login shells or root and we must have a tty */
- if ((cp2 = Strrchr(cp, (Char) '/')) != NULL) {
+ if (((cp2 = Strrchr(cp, (Char) '/')) != NULL) &&
+ (Strncmp(cp, STRpts, 3) != 0)) {
cp = cp2 + 1;
+ (Strncmp(cp, &STRslptssl[1], 3) != 0)) {
cp2 = cp2 + 1;
}
else
@@ -717,7 +718,16 @@ main(int argc, char **argv)
@@ -715,7 +716,16 @@ main(int argc, char **argv)
xfree(tmp2);
}
#else /* !WINNT_NATIVE */
@ -218,7 +218,7 @@
#endif /* WINNT_NATIVE */
/*
@@ -741,9 +751,9 @@ main(int argc, char **argv)
@@ -739,9 +749,9 @@ main(int argc, char **argv)
/* PATCH IDEA FROM Issei.Suzuki VERY THANKS */
#if defined(DSPMBYTE)
#if defined(NLS) && defined(LC_CTYPE)
@ -230,7 +230,7 @@
#endif
autoset_dspmbyte(str2short(tcp));
}
@@ -1252,6 +1262,9 @@ main(int argc, char **argv)
@@ -1247,6 +1257,9 @@ main(int argc, char **argv)
setintr = osetintr;
parintr = oparintr;
}

3
tcsh-6.16.00.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:79f7f2bb036fadaf0636c254c501f316425cfbaaafce54ddae5c8fd9d2e8392a
size 738912

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Wed Mar 25 12:23:46 CET 2009 - werner@suse.de
- Update to tcsh version V6.16.00
- Add patch to avoid endless loop due incorrect tty process group
(bnc#472866)
-------------------------------------------------------------------
Wed Jan 21 15:00:49 CET 2009 - werner@suse.de

View File

@ -1,5 +1,5 @@
#
# spec file for package tcsh (Version 6.15.00)
# spec file for package tcsh (Version 6.16.00)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@ -25,22 +25,23 @@ License: BSD 3-Clause
Group: System/Shells
Requires: gawk textutils
AutoReqProv: on
Version: 6.15.00
Release: 94
Version: 6.16.00
Release: 1
Summary: The C SHell
Source: ftp.astron.com:/pub/tcsh/tcsh-6.15.00.tar.bz2
Source: ftp.astron.com:/pub/tcsh/tcsh-6.16.00.tar.bz2
Source1: nls-iconv
Source2: bindkey.tcsh
Source3: complete.tcsh
Patch: tcsh-6.15.00.dif
Patch: tcsh-6.16.00.dif
Patch1: tcsh-6.15.00-spelling.dif
Patch2: tcsh-6.15.00-utf8.dif
Patch3: tcsh-6.15.00-pipe.dif
Patch4: tcsh-6.15.00-longjmp.dif
Patch5: tcsh-6.15.00-norm-cmd.dif
Patch6: tcsh-6.15.00-history.dif
Patch5: tcsh-6.16.00-norm-cmd.dif
Patch6: tcsh-6.16.00-history.dif
Patch7: tcsh-6.15.00-blanks.dif
Patch8: tcsh-6.15.00-fullpath.dif
Patch9: tcsh-6.16.00-grabpgrp.dif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
@ -150,6 +151,10 @@ Authors:
%{_datadir}/locale/*/LC_MESSAGES/tcsh
%changelog
* Wed Mar 25 2009 werner@suse.de
- Update to tcsh version V6.16.00
- Add patch to avoid endless loop due incorrect tty process group
(bnc#472866)
* Wed Jan 21 2009 werner@suse.de
- Reenable Alt-BackSpace for delete word in XTerm in UTF-8 mode
* Wed Nov 26 2008 werner@suse.de