diff options
Diffstat (limited to 'sbin/pdisk/partition_map.c')
-rw-r--r-- | sbin/pdisk/partition_map.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sbin/pdisk/partition_map.c b/sbin/pdisk/partition_map.c index e52f9d67fc9..26da73bc588 100644 --- a/sbin/pdisk/partition_map.c +++ b/sbin/pdisk/partition_map.c @@ -1,4 +1,4 @@ -/* $OpenBSD: partition_map.c,v 1.41 2016/01/21 01:37:18 krw Exp $ */ +/* $OpenBSD: partition_map.c,v 1.42 2016/01/21 02:52:52 krw Exp $ */ /* * partition_map.c - partition map routines @@ -91,7 +91,7 @@ struct partition_map_header * open_partition_map(char *name, int *valid_file) { struct partition_map_header *map; - int fd, writable; + int fd; fd = open_file_as_media(name, (rflag) ? O_RDONLY : O_RDWR); if (fd == -1) { @@ -100,7 +100,6 @@ open_partition_map(char *name, int *valid_file) *valid_file = 0; return NULL; } - writable = !rflag; *valid_file = 1; map = malloc(sizeof(struct partition_map_header)); @@ -110,7 +109,6 @@ open_partition_map(char *name, int *valid_file) return NULL; } map->name = name; - map->writable = (rflag) ? 0 : writable; map->changed = 0; map->written = 0; map->disk_order = NULL; @@ -367,7 +365,6 @@ create_partition_map(char *name, struct partition_map_header * oldmap) return NULL; } map->name = name; - map->writable = (rflag) ? 0 : 1; map->changed = 1; map->disk_order = NULL; map->base_order = NULL; |