review: proper error handling for OwnedAsyncWriter::write_all_at

https://github.com/neondatabase/neon/pull/10063#discussion_r1880439513

Signed-off-by: Yuchen Liang <yuchen@neon.tech>
This commit is contained in:
Yuchen Liang
2024-12-11 18:34:01 +00:00
parent 0066f23c65
commit 4b358f6a3c

View File

@@ -1332,8 +1332,8 @@ impl OwnedAsyncWriter for VirtualFile {
ctx: &RequestContext,
) -> std::io::Result<FullSlice<Buf>> {
let (buf, res) = VirtualFile::write_all_at(self, buf, offset, ctx).await;
let x = res.map(|_| buf).unwrap();
Ok(x)
res?;
Ok(buf)
}
}