From 76f153e120f032d2342e23ff2c7ea46e91af5bea Mon Sep 17 00:00:00 2001 From: ad Date: Sun, 20 Apr 2008 23:40:31 +0000 Subject: sync() a couple of times to benefit diagnosis of sloppy kernel code that crashes during boot to multiuser. --- sbin/savecore/savecore.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/sbin/savecore/savecore.c b/sbin/savecore/savecore.c index a736072fe86..5e06802b075 100644 --- a/sbin/savecore/savecore.c +++ b/sbin/savecore/savecore.c @@ -1,4 +1,4 @@ -/* $NetBSD: savecore.c,v 1.72 2008/01/15 14:26:42 ad Exp $ */ +/* $NetBSD: savecore.c,v 1.73 2008/04/20 23:40:31 ad Exp $ */ /*- * Copyright (c) 1986, 1992, 1993 @@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1986, 1992, 1993\n\ #if 0 static char sccsid[] = "@(#)savecore.c 8.5 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: savecore.c,v 1.72 2008/01/15 14:26:42 ad Exp $"); +__RCSID("$NetBSD: savecore.c,v 1.73 2008/04/20 23:40:31 ad Exp $"); #endif #endif /* not lint */ @@ -652,6 +652,15 @@ err2: syslog(LOG_WARNING, (void)fclose(fp); else (void)close(ofd); + + /* + * For development systems where the crash occurs during boot + * to multiuser. + */ + sync(); + sleep(1); + sync(); + sleep(1); } char * -- cgit