diff options
Diffstat (limited to 'src/dev/disk_image.cc')
-rw-r--r-- | src/dev/disk_image.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/dev/disk_image.cc b/src/dev/disk_image.cc index 8194eb507..e4907853f 100644 --- a/src/dev/disk_image.cc +++ b/src/dev/disk_image.cc @@ -308,13 +308,13 @@ SafeWriteSwap(ofstream &stream, const T &data) SafeWrite(stream, &swappeddata, sizeof(data)); } void -CowDiskImage::save() +CowDiskImage::save() const { save(filename); } void -CowDiskImage::save(const string &file) +CowDiskImage::save(const string &file) const { if (!initialized) panic("RawDiskImage not initialized"); @@ -408,19 +408,19 @@ CowDiskImage::write(const uint8_t *data, std::streampos offset) } void -CowDiskImage::serialize(ostream &os) +CowDiskImage::serialize(CheckpointOut &cp) const { string cowFilename = name() + ".cow"; SERIALIZE_SCALAR(cowFilename); - save(Checkpoint::dir() + "/" + cowFilename); + save(CheckpointIn::dir() + "/" + cowFilename); } void -CowDiskImage::unserialize(Checkpoint *cp, const string §ion) +CowDiskImage::unserialize(CheckpointIn &cp) { string cowFilename; UNSERIALIZE_SCALAR(cowFilename); - cowFilename = cp->cptDir + "/" + cowFilename; + cowFilename = cp.cptDir + "/" + cowFilename; open(cowFilename); } |