$OpenBSD: patch-src_core_pt_c,v 1.3 2018/03/20 22:03:35 sthen Exp $
Index: src/core/pt.c
--- src/core/pt.c.orig
+++ src/core/pt.c
@@ -255,8 +255,10 @@ int fork_process(int child_id, char *desc, int make_so
 {
 	int pid, child_process_no;
 	int ret;
+#ifndef HAVE_ARC4RANDOM
 	unsigned int new_seed1;
 	unsigned int new_seed2;
+#endif
 #ifdef USE_TCP
 	int sockfd[2];
 #endif
@@ -295,8 +297,10 @@ int fork_process(int child_id, char *desc, int make_so
 	}
 
 	child_process_no = *process_count;
+#ifndef HAVE_ARC4RANDOM
 	new_seed1=kam_rand();
 	new_seed2=random();
+#endif
 	pid = fork();
 	if (pid<0) {
 		lock_release(process_lock);
@@ -311,9 +315,11 @@ int fork_process(int child_id, char *desc, int make_so
 #ifdef USE_TCP
 		close_extra_socks(child_id, process_no);
 #endif /* USE_TCP */
+#ifndef HAVE_ARC4RANDOM
 		kam_srand(new_seed1);
 		fastrand_seed(kam_rand());
 		srandom(new_seed2+time(0));
+#endif
 		shm_malloc_on_fork();
 #ifdef PROFILING
 		monstartup((u_long) &_start, (u_long) &etext);
@@ -390,8 +396,10 @@ int fork_tcp_process(int child_id, char *desc, int r, 
 	int reader_fd[2]; /* for comm. with the tcp children read  */
 	int ret;
 	int i;
+#ifndef HAVE_ARC4RANDOM
 	unsigned int new_seed1;
 	unsigned int new_seed2;
+#endif
 
 	/* init */
 	sockfd[0]=sockfd[1]=-1;
@@ -429,8 +437,10 @@ int fork_tcp_process(int child_id, char *desc, int r, 
 	}
 
 	child_process_no = *process_count;
+#ifndef HAVE_ARC4RANDOM
 	new_seed1=kam_rand();
 	new_seed2=random();
+#endif
 	pid = fork();
 	if (pid<0) {
 		lock_release(process_lock);
@@ -452,9 +462,11 @@ int fork_tcp_process(int child_id, char *desc, int r, 
 			}
 		}
 		daemon_status_on_fork_cleanup();
+#ifndef HAVE_ARC4RANDOM
 		kam_srand(new_seed1);
 		fastrand_seed(kam_rand());
 		srandom(new_seed2+time(0));
+#endif
 		shm_malloc_on_fork();
 #ifdef PROFILING
 		monstartup((u_long) &_start, (u_long) &etext);
