Avoid infinite loop pendjob()-xprintf() when stdout is closed

Resolves: #690356
This commit is contained in:
Vojtech Vitek (V-Teq) 2011-03-24 16:07:23 +01:00
parent 0ab9a17439
commit 39067072fb
2 changed files with 16 additions and 0 deletions

View File

@ -0,0 +1,10 @@
--- tcsh-6.17.00/sh.proc.c.orig 2011-02-03 12:31:14.000000000 -0700
+++ tcsh-6.17.00/sh.proc.c 2011-02-03 12:32:00.000000000 -0700
@@ -910,6 +910,7 @@
if (pcurrjob && (pcurrjob->p_flags & (PFOREGND | PSTOPPED)) == 0) {
pp = pcurrjob;
+ pcurrjob = 0;
while (pp->p_procid != pp->p_jobid)
pp = pp->p_friends;
xprintf("[%d]", pp->p_index);

View File

@ -36,6 +36,8 @@ Patch21: tcsh-6.17.00-dont-set-empty-remotehost.patch
Patch22: tcsh-6.17.00-dont-print-history-on-verbose.patch Patch22: tcsh-6.17.00-dont-print-history-on-verbose.patch
# Accepted by upstream (tcsh-6.17.03b http://bugs.gw.com/view.php?id=113): # Accepted by upstream (tcsh-6.17.03b http://bugs.gw.com/view.php?id=113):
Patch23: tcsh-6.17.00-variable-names.patch Patch23: tcsh-6.17.00-variable-names.patch
# Accepted by upstream (tcsh-6.17.05b http://mx.gw.com/pipermail/tcsh-bugs/2011-March/000727.html):
Patch24: tcsh-6.17.00-avoid-infinite-loop-pendjob-xprintf.patch
Provides: csh = %{version} Provides: csh = %{version}
Requires(post): grep Requires(post): grep
Requires(postun): coreutils, grep Requires(postun): coreutils, grep
@ -73,6 +75,7 @@ like syntax.
%patch21 -p1 -b .dont-set-empty-remotehost %patch21 -p1 -b .dont-set-empty-remotehost
%patch22 -p1 -b .dont-print-history-on-verbose %patch22 -p1 -b .dont-print-history-on-verbose
%patch23 -p1 -b .variable-names %patch23 -p1 -b .variable-names
%patch24 -p1 -b .avoid-infinite-loop-pendjob-xprintf
for i in Fixes WishList; do for i in Fixes WishList; do
iconv -f iso-8859-1 -t utf-8 "$i" > "${i}_" && \ iconv -f iso-8859-1 -t utf-8 "$i" > "${i}_" && \
@ -146,6 +149,9 @@ fi
%{_mandir}/man1/*.1* %{_mandir}/man1/*.1*
%changelog %changelog
- Avoid infinite loop pendjob()-xprintf() when stdout is closed
Resolves: #690356
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 6.17-14 * Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 6.17-14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild