summaryrefslogtreecommitdiff
path: root/src/dev
diff options
context:
space:
mode:
Diffstat (limited to 'src/dev')
-rw-r--r--src/dev/disk_image.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/dev/disk_image.cc b/src/dev/disk_image.cc
index b8386bc3d..792a31204 100644
--- a/src/dev/disk_image.cc
+++ b/src/dev/disk_image.cc
@@ -171,7 +171,8 @@ CowDiskImage::CowDiskImage(const Params *p)
init(p->table_size);
} else {
if (!open(filename)) {
- assert(!p->read_only && "why have a non-existent read only file?");
+ if (p->read_only)
+ fatal("could not open read-only file");
init(p->table_size);
}