From ffe687db775393a05cdeae8550f9b6595d424678 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Tue, 8 Oct 1996 21:20:04 +0000 Subject: (proc_stat_set_flags): Get rid of INAPP macro. Fix preconditions of PSTAT_SUSPEND_COUNT. --- libps/procstat.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/libps/procstat.c b/libps/procstat.c index 5541a747..461d8113 100644 --- a/libps/procstat.c +++ b/libps/procstat.c @@ -772,9 +772,6 @@ proc_stat_set_flags (struct proc_stat *ps, ps_flags_t flags) need = flags & ~have & ~ps->failed; - /* Returns true if some flag in FLAGS is `inapplicable'. */ -#define INAPP(flags) (flags & (need & ~have) & ps->inapp) - /* Returns true if (1) FLAGS is in NEED, and (2) the appropriate preconditions PRECOND are available; if only (1) is true, FLAG is added to the INAPP set if appropiate (to distinguish it from an error), and @@ -790,7 +787,7 @@ proc_stat_set_flags (struct proc_stat *ps, ps_flags_t flags) else \ { \ val = 0; \ - if (INAPP (_precond)) \ + if (_precond & ps->inapp) \ ps->inapp |= __flag; \ } \ val; \ @@ -830,10 +827,8 @@ proc_stat_set_flags (struct proc_stat *ps, ps_flags_t flags) later. */ have = set_procinfo_flags (ps, need & ~have & test_msgport_flags, have); - if (NEED (PSTAT_SUSPEND_COUNT, - ((have & PSTAT_PID) - ? (have & PSTAT_TASK_BASIC) - : (have & PSTAT_THREAD_BASIC)))) + if (NEED (PSTAT_SUSPEND_COUNT, + ((have & PSTAT_PID) ? PSTAT_TASK_BASIC : PSTAT_THREAD_BASIC))) { if (have & PSTAT_PID) ps->suspend_count = ps->task_basic_info->suspend_count; -- cgit v1.2.3