mirror of
https://github.com/RGBCube/serenity
synced 2025-07-24 22:37:34 +00:00
LibCore: Return EBADF
on unsupported stream operations
This commit is contained in:
parent
e65767c2e7
commit
1ca62de558
6 changed files with 9 additions and 8 deletions
|
@ -729,7 +729,7 @@ ErrorOr<void> WrappedAKInputStream::discard(size_t discarded_bytes)
|
|||
|
||||
ErrorOr<size_t> WrappedAKInputStream::write(ReadonlyBytes)
|
||||
{
|
||||
VERIFY_NOT_REACHED();
|
||||
return Error::from_errno(EBADF);
|
||||
}
|
||||
|
||||
bool WrappedAKInputStream::is_eof() const
|
||||
|
@ -753,7 +753,7 @@ WrappedAKOutputStream::WrappedAKOutputStream(NonnullOwnPtr<OutputStream> stream)
|
|||
|
||||
ErrorOr<Bytes> WrappedAKOutputStream::read(Bytes)
|
||||
{
|
||||
VERIFY_NOT_REACHED();
|
||||
return Error::from_errno(EBADF);
|
||||
}
|
||||
|
||||
ErrorOr<size_t> WrappedAKOutputStream::write(ReadonlyBytes bytes)
|
||||
|
@ -768,7 +768,7 @@ ErrorOr<size_t> WrappedAKOutputStream::write(ReadonlyBytes bytes)
|
|||
|
||||
bool WrappedAKOutputStream::is_eof() const
|
||||
{
|
||||
VERIFY_NOT_REACHED();
|
||||
return true;
|
||||
}
|
||||
|
||||
bool WrappedAKOutputStream::is_open() const
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue