Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/miscfs/procfs Add calls to lock the proclist as appropri...



details:   https://anonhg.NetBSD.org/src/rev/afb27f77eaf1
branches:  trunk
changeset: 474901:afb27f77eaf1
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Sun Jul 25 18:33:47 1999 +0000

description:
Add calls to lock the proclist as appropriate.

diffstat:

 sys/miscfs/procfs/procfs_vnops.c |  4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diffs (25 lines):

diff -r dec45df038b8 -r afb27f77eaf1 sys/miscfs/procfs/procfs_vnops.c
--- a/sys/miscfs/procfs/procfs_vnops.c  Sun Jul 25 18:05:31 1999 +0000
+++ b/sys/miscfs/procfs/procfs_vnops.c  Sun Jul 25 18:33:47 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: procfs_vnops.c,v 1.63 1999/07/14 23:52:22 thorpej Exp $        */
+/*     $NetBSD: procfs_vnops.c,v 1.64 1999/07/25 18:33:47 thorpej Exp $        */
 
 /*
  * Copyright (c) 1993 Jan-Simon Pendry
@@ -932,6 +932,7 @@
                 * XXX: THIS LOOP ASSUMES THAT allproc IS THE FIRST
                 * PROCLIST IN THE proclists!
                 */
+               proclist_lock_read();
                pd = proclists;
 #ifdef PROCFS_ZOMBIE
        again:
@@ -983,6 +984,7 @@
                if (p == NULL && pd->pd_list != NULL)
                        goto again;
 #endif
+               proclist_unlock_read();
                ncookies = nc;
 
                break;



Home | Main Index | Thread Index | Old Index