Module Name:    src
Committed By:   riastradh
Date:           Fri May  1 15:52:38 UTC 2020

Modified Files:
        src/etc/rc.d: random_seed

Log Message:
Don't delete the random seed before issuing `rndctl -S'.

`rndctl -S' can replace the file just fine, and deleting it ahead of
time adds a window during which we can lose the seed altogether if
the system is interrupted by a crash or power outage.

XXX pullup


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/etc/rc.d/random_seed

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/etc/rc.d/random_seed
diff -u src/etc/rc.d/random_seed:1.8 src/etc/rc.d/random_seed:1.9
--- src/etc/rc.d/random_seed:1.8	Sun Feb 23 08:53:14 2020
+++ src/etc/rc.d/random_seed	Fri May  1 15:52:38 2020
@@ -1,6 +1,6 @@
 #!/bin/sh
 #
-# $NetBSD: random_seed,v 1.8 2020/02/23 08:53:14 riastradh Exp $
+# $NetBSD: random_seed,v 1.9 2020/05/01 15:52:38 riastradh Exp $
 #
 
 # PROVIDE: random_seed
@@ -93,8 +93,6 @@ random_save()
 	oum="$(umask)"
 	umask 077
 
-	rm -Pf "${random_file}"
-
 	if ! fs_safe "$(dirname "${random_file}")"; then
 		umask "${oum}"
 		return 1

Reply via email to