mirror of
https://github.com/mikedilger/chorus.git
synced 2026-05-03 06:51:42 +00:00
Don't just presume ErrorKind::Other is always "Out of space"
This commit is contained in:
parent
08bbcb19a7
commit
8c239499ff
@ -98,7 +98,7 @@ impl EventStore {
|
||||
Ok(offset) => return Ok(offset),
|
||||
Err(e) => {
|
||||
if e.kind() == std::io::ErrorKind::Other {
|
||||
// presume it was Out of Space
|
||||
if e.to_string() == "Out of space" {
|
||||
// Determine the new size
|
||||
let new_file_len = {
|
||||
let file_len = self.event_map_file_len.load(Ordering::Relaxed);
|
||||
@ -120,6 +120,9 @@ impl EventStore {
|
||||
} else {
|
||||
return Err(e.into());
|
||||
}
|
||||
} else {
|
||||
return Err(e.into());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user