summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2000-12-03 02:09:47 +0000
committerjhb <jhb@FreeBSD.org>2000-12-03 02:09:47 +0000
commit5870e2e9f0d121f6e3d2e14a7ed4da6cc3ae7832 (patch)
tree9d72fd87a79efb88cfacaf837f0cecc4ab2936eb
parent134e569eff77ed4d6a038dbc37233750b4d94113 (diff)
downloadFreeBSD-src-5870e2e9f0d121f6e3d2e14a7ed4da6cc3ae7832.zip
FreeBSD-src-5870e2e9f0d121f6e3d2e14a7ed4da6cc3ae7832.tar.gz
Fix up a whitespace glitch in PHOLD() and fix it to use do { ... } while(0)
instead of { ... }.
-rw-r--r--sys/sys/proc.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/sys/proc.h b/sys/sys/proc.h
index 1cb164b..52d5c9e 100644
--- a/sys/sys/proc.h
+++ b/sys/sys/proc.h
@@ -440,10 +440,10 @@ extern void stopevent(struct proc*, unsigned int, unsigned int);
} while (0)
/* hold process U-area in memory, normally for ptrace/procfs work */
-#define PHOLD(p) { \
- if ((p)->p_lock++ == 0 && ((p)->p_flag & P_INMEM) == 0) \
+#define PHOLD(p) do { \
+ if ((p)->p_lock++ == 0 && ((p)->p_flag & P_INMEM) == 0) \
faultin(p); \
-}
+} while(0)
#define PRELE(p) (--(p)->p_lock)
#define PIDHASH(pid) (&pidhashtbl[(pid) & pidhash])
OpenPOWER on IntegriCloud