fix: buffer size typo (#25039)
parent
a5eba2f8f2
commit
84b38f5a06
|
@ -261,7 +261,7 @@ impl WalSegmentWriterImpl {
|
||||||
f,
|
f,
|
||||||
bytes_written,
|
bytes_written,
|
||||||
sequence_number: SequenceNumber::new(0),
|
sequence_number: SequenceNumber::new(0),
|
||||||
buffer: Vec::with_capacity(8 * 1204), // 8kiB initial size
|
buffer: Vec::with_capacity(8 * 1024), // 8kiB initial size
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
pub fn open(root: PathBuf, segment_id: SegmentId) -> Result<Self> {
|
pub fn open(root: PathBuf, segment_id: SegmentId) -> Result<Self> {
|
||||||
|
@ -280,7 +280,7 @@ impl WalSegmentWriterImpl {
|
||||||
.try_into()
|
.try_into()
|
||||||
.expect("file length must fit in usize"),
|
.expect("file length must fit in usize"),
|
||||||
sequence_number: file_info.last_sequence_number,
|
sequence_number: file_info.last_sequence_number,
|
||||||
buffer: Vec::with_capacity(8 * 1204), // 8kiB initial size
|
buffer: Vec::with_capacity(8 * 1024), // 8kiB initial size
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
Err(Error::FileDoesntExist(path.to_path_buf()))
|
Err(Error::FileDoesntExist(path.to_path_buf()))
|
||||||
|
|
Loading…
Reference in New Issue