diff options
author | gad <gad@FreeBSD.org> | 2004-06-23 11:28:17 +0000 |
---|---|---|
committer | gad <gad@FreeBSD.org> | 2004-06-23 11:28:17 +0000 |
commit | 2e340f35b76c7b595dc974e2f8d29096a54412a0 (patch) | |
tree | 073d8293b14712e96490eeb5b9a4cba71441db5d /bin/ps/ps.c | |
parent | 7de2955c800420ef1260f2fb6be768dcd14d25b7 (diff) | |
download | FreeBSD-src-2e340f35b76c7b595dc974e2f8d29096a54412a0.zip FreeBSD-src-2e340f35b76c7b595dc974e2f8d29096a54412a0.tar.gz |
In the sorting routine, sort by thread-id if two processes have the same PID.
Submitted by: Cyrille Lefevre
Diffstat (limited to 'bin/ps/ps.c')
-rw-r--r-- | bin/ps/ps.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/bin/ps/ps.c b/bin/ps/ps.c index 98e20f4..82b6f9f 100644 --- a/bin/ps/ps.c +++ b/bin/ps/ps.c @@ -1025,7 +1025,9 @@ pscomp(const void *a, const void *b) DIFF_RETURN(ka, kb, ki_p->ki_tdev); } + /* PID's and TID's (threads) are sorted in ascending order. */ DIFF_RETURN(ka, kb, ki_p->ki_pid); + DIFF_RETURN(ka, kb, ki_p->ki_tid); return (0); } #undef DIFF_RETURN |