summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorart <art@openbsd.org>2000-11-08 05:38:47 +0000
committerart <art@openbsd.org>2000-11-08 05:38:47 +0000
commit88b72149745f4f695783b8332ef1b26f0408c9db (patch)
tree3b3626109a8f42d1676f65dd7fdb6d17ef7fe1dc
parentsync (diff)
downloadwireguard-openbsd-88b72149745f4f695783b8332ef1b26f0408c9db.tar.xz
wireguard-openbsd-88b72149745f4f695783b8332ef1b26f0408c9db.zip
If MD code has defined curproc, don't do it here.
This is not a perfect solution.
-rw-r--r--sys/kern/init_main.c8
-rw-r--r--sys/sys/proc.h4
2 files changed, 9 insertions, 3 deletions
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c
index b0c9edbd48b..7b0f332ce2b 100644
--- a/sys/kern/init_main.c
+++ b/sys/kern/init_main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: init_main.c,v 1.55 2000/06/18 03:07:48 angelos Exp $ */
+/* $OpenBSD: init_main.c,v 1.56 2000/11/08 05:41:04 art Exp $ */
/* $NetBSD: init_main.c,v 1.84.4.1 1996/06/02 09:08:06 mrg Exp $ */
/*
@@ -118,7 +118,9 @@ struct pcred cred0;
struct filedesc0 filedesc0;
struct plimit limit0;
struct vmspace vmspace0;
-struct proc *curproc = &proc0;
+#ifndef curproc
+struct proc *curproc;
+#endif
struct proc *initproc;
int cmask = CMASK;
@@ -394,6 +396,7 @@ main(framep)
VREF(filedesc0.fd_fd.fd_cdir);
VOP_UNLOCK(rootvnode, 0, p);
filedesc0.fd_fd.fd_rdir = NULL;
+
#if defined(UVM)
uvm_swap_init();
#else
@@ -618,6 +621,7 @@ start_init(arg)
arg0 = ucp;
uap = (char **)((u_long)ucp & ~ALIGNBYTES);
#endif
+
/*
* Move out the arg pointers.
*/
diff --git a/sys/sys/proc.h b/sys/sys/proc.h
index 34553df974a..dd8b7d7924f 100644
--- a/sys/sys/proc.h
+++ b/sys/sys/proc.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: proc.h,v 1.32 2000/07/07 15:57:01 art Exp $ */
+/* $OpenBSD: proc.h,v 1.33 2000/11/08 05:38:47 art Exp $ */
/* $NetBSD: proc.h,v 1.44 1996/04/22 01:23:21 christos Exp $ */
/*-
@@ -321,7 +321,9 @@ extern u_long pidhash;
extern LIST_HEAD(pgrphashhead, pgrp) *pgrphashtbl;
extern u_long pgrphash;
+#ifndef curproc
extern struct proc *curproc; /* Current running proc. */
+#endif
extern struct proc proc0; /* Process slot for swapper. */
extern int nprocs, maxproc; /* Current and max number of procs. */
extern int randompid; /* fork() should create random pid's */