Collect status from dead jobs and don't invoke the callback until both

all input (the socket is closed) and status is available.
This commit is contained in:
Nicholas Marriott
2009-10-11 07:20:16 +00:00
parent 4bc0f6e7e9
commit ff4b4e667a
3 changed files with 35 additions and 6 deletions

4
tmux.h
View File

@ -567,6 +567,7 @@ ARRAY_DECL(keylist, int);
struct job {
char *cmd;
pid_t pid;
int status;
struct client *client;
@ -577,6 +578,9 @@ struct job {
void (*freefn)(void *);
void *data;
int flags;
#define JOB_DONE 0x1
RB_ENTRY(job) entry;
SLIST_ENTRY(job) lentry;
};