@@ -139,17 +139,17 @@ class SpecialEnv : public EnvWrapper {
139
139
public:
140
140
DataFile (SpecialEnv* env, WritableFile* base) : env_(env), base_(base) {}
141
141
~DataFile () { delete base_; }
142
- Status Append (const Slice& data) {
142
+ Status Append (const Slice& data) override {
143
143
if (env_->no_space_ .load (std::memory_order_acquire)) {
144
144
// Drop writes on the floor
145
145
return Status::OK ();
146
146
} else {
147
147
return base_->Append (data);
148
148
}
149
149
}
150
- Status Close () { return base_->Close (); }
151
- Status Flush () { return base_->Flush (); }
152
- Status Sync () {
150
+ Status Close () override { return base_->Close (); }
151
+ Status Flush () override { return base_->Flush (); }
152
+ Status Sync () override {
153
153
if (env_->data_sync_error_ .load (std::memory_order_acquire)) {
154
154
return Status::IOError (" simulated data sync error" );
155
155
}
@@ -168,16 +168,16 @@ class SpecialEnv : public EnvWrapper {
168
168
public:
169
169
ManifestFile (SpecialEnv* env, WritableFile* b) : env_(env), base_(b) {}
170
170
~ManifestFile () { delete base_; }
171
- Status Append (const Slice& data) {
171
+ Status Append (const Slice& data) override {
172
172
if (env_->manifest_write_error_ .load (std::memory_order_acquire)) {
173
173
return Status::IOError (" simulated writer error" );
174
174
} else {
175
175
return base_->Append (data);
176
176
}
177
177
}
178
- Status Close () { return base_->Close (); }
179
- Status Flush () { return base_->Flush (); }
180
- Status Sync () {
178
+ Status Close () override { return base_->Close (); }
179
+ Status Flush () override { return base_->Flush (); }
180
+ Status Sync () override {
181
181
if (env_->manifest_sync_error_ .load (std::memory_order_acquire)) {
182
182
return Status::IOError (" simulated sync error" );
183
183
} else {
0 commit comments