diff options
author | Marco Peereboom <marco@cvs.openbsd.org> | 2007-05-26 14:49:51 +0000 |
---|---|---|
committer | Marco Peereboom <marco@cvs.openbsd.org> | 2007-05-26 14:49:51 +0000 |
commit | e8dba0b412e84791e5df0eb1dd3a50728f8e811a (patch) | |
tree | cdf35c9b6ecba5c1e16870ba2ebd27f87feb9d43 /sys/dev | |
parent | 5160377a6677b80fa0cd6587594e31c782942142 (diff) |
Oops reintroduce check for SR_MAGIC to ensure that we care about metadata;
not doing so resulted in a partial bringup of a volume that was being created;
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/softraid.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/dev/softraid.c b/sys/dev/softraid.c index 36a316a8862..2e630aba85e 100644 --- a/sys/dev/softraid.c +++ b/sys/dev/softraid.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid.c,v 1.45 2007/05/26 14:30:26 marco Exp $ */ +/* $OpenBSD: softraid.c,v 1.46 2007/05/26 14:49:50 marco Exp $ */ /* * Copyright (c) 2007 Marco Peereboom <marco@peereboom.us> * @@ -1053,9 +1053,12 @@ sr_read_meta(struct sr_discipline *sd) continue; } + if (m->ssd_magic != SR_MAGIC) + continue; + /* validate metadata */ if (sr_validate_metadata(sc, ch_entry->src_dev_mm, m)) { - printf("%s: invalid metadatada\n", DEVNAME(sc)); + printf("%s: invalid metadata\n", DEVNAME(sc)); no_chunk = -1; goto bad; } |