[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Bash 3.2: defect in jobs.c
From: |
jim . brown |
Subject: |
Bash 3.2: defect in jobs.c |
Date: |
Thu, 8 Mar 2007 12:44:34 -0500 (EST) |
User-agent: |
SquirrelMail/1.4.8-2.el3 |
Missing macro wrappers for a few uses of status from struct PROCESS.
Some compilers dislike this.
diff -r -c bash-3.2.orig/jobs.c bash-3.2/jobs.c
*** bash-3.2.orig/jobs.c Sat Jul 29 16:40:48 2006
--- bash-3.2/jobs.c Thu Mar 8 09:48:16 2007
***************
*** 2225,2231 ****
p = jobs[job]->pipe;
do
{
! if (p->status != EXECUTION_SUCCESS) fail = p->status;
p = p->next;
}
while (p != jobs[job]->pipe);
--- 2225,2231 ----
p = jobs[job]->pipe;
do
{
! if (WSTATUS(p->status) != EXECUTION_SUCCESS) fail =
WSTATUS(p->status);
p = p->next;
}
while (p != jobs[job]->pipe);
***************
*** 2234,2240 ****
for (p = jobs[job]->pipe; p->next != jobs[job]->pipe; p = p->next)
;
! return (p->status);
}
/* Return the exit status of job JOB. This is the exit status of the last
--- 2234,2240 ----
for (p = jobs[job]->pipe; p->next != jobs[job]->pipe; p = p->next)
;
! return (WSTATUS(p->status));
}
/* Return the exit status of job JOB. This is the exit status of the last
***************
*** 2367,2373 ****
if (r == -1 && errno == ECHILD)
{
child->running = PS_DONE;
! child->status = 0; /* XXX -- can't find true status */
js.c_living = 0; /* no living child processes */
if (job != NO_JOB)
{
--- 2367,2373 ----
if (r == -1 && errno == ECHILD)
{
child->running = PS_DONE;
! WSTATUS(child->status) = 0; /* XXX -- can't find true status */
js.c_living = 0; /* no living child processes */
if (job != NO_JOB)
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Bash 3.2: defect in jobs.c,
jim . brown <=