summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPedro Martelletto <pedro@cvs.openbsd.org>2006-04-14 16:38:43 +0000
committerPedro Martelletto <pedro@cvs.openbsd.org>2006-04-14 16:38:43 +0000
commitad687ec4152fbe970070f3874fe6abb322e718ee (patch)
treef05b379ae443679af3bdc8ff8b07523cb05a2037
parent626e6e5b6e42f3d1610b3dc87c8465d54677c2f4 (diff)
Remove duplicate code, okay ray@
-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 56505f28298..cb7e5f643cb 100644
--- a/sbin/disklabel/editor.c
+++ b/sbin/disklabel/editor.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: editor.c,v 1.101 2005/12/05 21:30:40 miod Exp $ */
+/* $OpenBSD: editor.c,v 1.102 2006/04/14 16:38:42 pedro 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.101 2005/12/05 21:30:40 miod Exp $";
+static char rcsid[] = "$OpenBSD: editor.c,v 1.102 2006/04/14 16:38:42 pedro Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -496,8 +496,6 @@ editor_add(struct disklabel *lp, char **mp, u_int32_t *freep, char *p)
/* Set defaults */
pp = &lp->d_partitions[partno];
- if (partno >= lp->d_npartitions)
- lp->d_npartitions = partno + 1;
memset(pp, 0, sizeof(*pp));
pp->p_size = *freep;
pp->p_offset = next_offset(lp, &pp->p_size);