summaryrefslogtreecommitdiffstats
path: root/sbin/disklabel/editor.c
diff options
context:
space:
mode:
authorkrw <krw@openbsd.org>2009-05-17 01:17:12 +0000
committerkrw <krw@openbsd.org>2009-05-17 01:17:12 +0000
commitaf9b716704107c49c58335c5de01a9cd422411d8 (patch)
tree7824bd77b93188ad94f41bfb0c5f3c8a7e9cd076 /sbin/disklabel/editor.c
parentInitialize mountpoints[] when going past again:, since a (diff)
downloadwireguard-openbsd-af9b716704107c49c58335c5de01a9cd422411d8.tar.xz
wireguard-openbsd-af9b716704107c49c58335c5de01a9cd422411d8.zip
Write out mountpoint info in writelabel() after label successfully
written, rather than every time editor_alloc() is called. Respect '-n' for mountpoint info. Reduces surprise appearance of files when you 'x' out of Editor. "my sunglasses did not go dark" deraadt@
Diffstat (limited to 'sbin/disklabel/editor.c')
-rw-r--r--sbin/disklabel/editor.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sbin/disklabel/editor.c b/sbin/disklabel/editor.c
index 3093058a0c1..cba414f145c 100644
--- a/sbin/disklabel/editor.c
+++ b/sbin/disklabel/editor.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: editor.c,v 1.210 2009/05/17 01:06:56 krw Exp $ */
+/* $OpenBSD: editor.c,v 1.211 2009/05/17 01:17:12 krw Exp $ */
/*
* Copyright (c) 1997-2000 Todd C. Miller <Todd.Miller@courtesan.com>
@@ -17,7 +17,7 @@
*/
#ifndef lint
-static char rcsid[] = "$OpenBSD: editor.c,v 1.210 2009/05/17 01:06:56 krw Exp $";
+static char rcsid[] = "$OpenBSD: editor.c,v 1.211 2009/05/17 01:17:12 krw Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -657,8 +657,6 @@ cylinderalign:
free(alloc);
memcpy(lp_org, lp, sizeof(struct disklabel));
- /* Save mountpoint info if there is any. */
- mpsave(lp);
}
/*