diff options
author | 2007-12-23 16:15:21 +0000 | |
---|---|---|
committer | 2007-12-23 16:15:21 +0000 | |
commit | 07a770d03bfd6e924dda0bd476bd2f4c008a071a (patch) | |
tree | 5fd7bf90177e8ce992b8dc19f7145583eba54e69 | |
parent | Remove DMMU_MISS_2; it's identical to DMMU_MISS. (diff) | |
download | wireguard-openbsd-07a770d03bfd6e924dda0bd476bd2f4c008a071a.tar.xz wireguard-openbsd-07a770d03bfd6e924dda0bd476bd2f4c008a071a.zip |
Setting p_fstype to the number of free sectors can't be right. Instead, set
the partition size with DL_SETPSIZE(pp, *freep).
-rw-r--r-- | sbin/disklabel/editor.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sbin/disklabel/editor.c b/sbin/disklabel/editor.c index 96881391201..329f1ce757a 100644 --- a/sbin/disklabel/editor.c +++ b/sbin/disklabel/editor.c @@ -1,4 +1,4 @@ -/* $OpenBSD: editor.c,v 1.125 2007/09/02 15:19:23 deraadt Exp $ */ +/* $OpenBSD: editor.c,v 1.126 2007/12/23 16:15:21 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.125 2007/09/02 15:19:23 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: editor.c,v 1.126 2007/12/23 16:15:21 krw Exp $"; #endif /* not lint */ #include <sys/types.h> @@ -673,7 +673,7 @@ editor_modify(struct disklabel *lp, char **mp, u_int64_t *freep, char *p) "Warning, need %llu sectors but there are only %llu " "free. Setting size to %llu.\n", DL_GETPSIZE(pp), *freep, *freep); - pp->p_fstype = *freep; + DL_SETPSIZE(pp, *freep); *freep = 0; } else *freep -= DL_GETPSIZE(pp); /* have enough space */ |